Beispiel #1
0
 def _commit_resume(self):
     logger.debug("_commit_resume()")
     last_storage = SessionStorageRepository().get_last_storage()
     assert last_storage is not None, "no saved session to resume"
     self._manager = SessionManager.load_session(
         self.job_list, last_storage, lambda session: self)
     logger.debug("_commit_resume() finished")
Beispiel #2
0
 def _commit_clean(self):
     logger.debug("_commit_clean()")
     if self._manager:
         self._manager.destroy()
         self._manager.create_session(self.job_list)
     self._manager = SessionManager.create_session(
         self.job_list, legacy_mode=True)
     self._manager._state = self
Beispiel #3
0
 def _commit_resume(self):
     logger.debug("_commit_resume()")
     last_storage = SessionStorageRepository().get_last_storage()
     assert last_storage is not None, "no saved session to resume"
     self._manager = SessionManager.load_session(self.job_list,
                                                 last_storage,
                                                 lambda session: self)
     logger.debug("_commit_resume() finished")
Beispiel #4
0
 def _commit_clean(self):
     logger.debug("_commit_clean()")
     if self._manager:
         self._manager.destroy()
         self._manager.create_session(self.job_list)
     self._manager = SessionManager.create_session(self.job_list,
                                                   legacy_mode=True)
     self._manager._state = self
Beispiel #5
0
 def _commit_open(self):
     logger.debug("_commit_open()")
     self._manager = SessionManager.create_session(
         self.job_list, legacy_mode=True)
     # Compatibility hack. Since session manager is supposed to
     # create and manage both session state and session storage
     # we need to inject ourselves into its internal attribute.
     # This way it will keep operating on this instance in the
     # essential checkpoint() method.
     self._manager._state = self
Beispiel #6
0
 def _commit_open(self):
     logger.debug("_commit_open()")
     self._manager = SessionManager.create_session(self.job_list,
                                                   legacy_mode=True)
     # Compatibility hack. Since session manager is supposed to
     # create and manage both session state and session storage
     # we need to inject ourselves into its internal attribute.
     # This way it will keep operating on this instance in the
     # essential checkpoint() method.
     self._manager._state = self