[CalendarServer-changes] [10281] CalendarServer/branches/users/glyph/queue-locking-and-timing

source_changes at macosforge.org source_changes at macosforge.org
Fri Jan 4 16:39:51 PST 2013


Revision: 10281
          http://trac.calendarserver.org//changeset/10281
Author:   glyph at apple.com
Date:     2013-01-04 16:39:51 -0800 (Fri, 04 Jan 2013)
Log Message:
-----------
Right, this is meant to select a point in the ''past'', so let's subtract rather than add.

Modified Paths:
--------------
    CalendarServer/branches/users/glyph/queue-locking-and-timing/twext/enterprise/queue.py

Property Changed:
----------------
    CalendarServer/branches/users/glyph/queue-locking-and-timing/

Modified: CalendarServer/branches/users/glyph/queue-locking-and-timing/twext/enterprise/queue.py
===================================================================
--- CalendarServer/branches/users/glyph/queue-locking-and-timing/twext/enterprise/queue.py	2013-01-05 00:39:50 UTC (rev 10280)
+++ CalendarServer/branches/users/glyph/queue-locking-and-timing/twext/enterprise/queue.py	2013-01-05 00:39:51 UTC (rev 10281)
@@ -1218,13 +1218,12 @@
                 )
             for itemType in self.allWorkItemTypes():
                 tooLate = datetime.utcfromtimestamp(
-                    self.reactor.seconds() + self.queueProcessTimeout
+                    self.reactor.seconds() - self.queueProcessTimeout
                 )
-                for overdueItem in (
-                        yield itemType.query(
-                            txn,
-                            (itemType.notBefore < tooLate)
-                    )):
+                overdueItems = (yield itemType.query(
+                    txn, (itemType.notBefore < tooLate))
+                )
+                for overdueItem in overdueItems:
                     peer = self.choosePerformer()
                     yield peer.performWork(overdueItem.table,
                                            overdueItem.workID)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20130104/49d4fa6e/attachment-0001.html>


More information about the calendarserver-changes mailing list