Пример #1
0
 def with_for_update(self, *args, **kwargs):
     for table in self._get_tables():
         dd.register_lock(table)
     return super(DeadlockDetectingQuery, self).with_for_update(*args, **kwargs)
Пример #2
0
 def with_lockmode(self, mode):
     """with_lockmode function wrapper for deadlock detection
     """
     for table in self._get_tables():
         dd.register_lock(table)
     return super(NoCacheQuery, self).with_lockmode(mode)