server/session.py
changeset 3998 94cc7cad3d2d
parent 3589 a5432f99f2d9
parent 3986 cc29eddf51ad
child 4006 c89be0bdf943
equal deleted inserted replaced
3895:92ead039d3d0 3998:94cc7cad3d2d
   474                     for operation in processed:
   474                     for operation in processed:
   475                         operation.handle_event('revert%s_event' % trstate)
   475                         operation.handle_event('revert%s_event' % trstate)
   476                     self.rollback(reset_pool)
   476                     self.rollback(reset_pool)
   477                     raise
   477                     raise
   478             self.pool.commit()
   478             self.pool.commit()
       
   479             self.commit_state = trstate = 'postcommit'
       
   480             while self.pending_operations:
       
   481                 operation = self.pending_operations.pop(0)
       
   482                 operation.processed = trstate
       
   483                 try:
       
   484                     operation.handle_event('%s_event' % trstate)
       
   485                 except:
       
   486                     self.exception('error while %sing', trstate)
       
   487             self.debug('%s session %s done', trstate, self.id)
   479         finally:
   488         finally:
   480             self._touch()
   489             self._touch()
   481             self.commit_state = None
   490             self.commit_state = None
   482             self.pending_operations[:] = []
   491             self.pending_operations[:] = []
   483             self.transaction_data.clear()
   492             self.transaction_data.clear()