[CalendarServer-changes] [11069] CalendarServer/trunk/calendarserver/tools

source_changes at macosforge.org source_changes at macosforge.org
Fri Apr 19 11:52:27 PDT 2013


Revision: 11069
          http://trac.calendarserver.org//changeset/11069
Author:   sagen at apple.com
Date:     2013-04-19 11:52:27 -0700 (Fri, 19 Apr 2013)
Log Message:
-----------
Command line tools now schedule group cacher updates in the past so the poller picks them up more quickly

Modified Paths:
--------------
    CalendarServer/trunk/calendarserver/tools/principals.py
    CalendarServer/trunk/calendarserver/tools/util.py

Modified: CalendarServer/trunk/calendarserver/tools/principals.py
===================================================================
--- CalendarServer/trunk/calendarserver/tools/principals.py	2013-04-19 17:26:34 UTC (rev 11068)
+++ CalendarServer/trunk/calendarserver/tools/principals.py	2013-04-19 18:52:27 UTC (rev 11069)
@@ -505,7 +505,8 @@
         membersProperty = davxml.GroupMemberSet(*memberURLs)
         yield subPrincipal.writeProperty(membersProperty, None)
         if store is not None:
-            yield scheduleNextGroupCachingUpdate(store, 0)
+            # Schedule in the past so the queue poller picks it up quickly
+            yield scheduleNextGroupCachingUpdate(store, -10*60)
 
 
 @inlineCallbacks

Modified: CalendarServer/trunk/calendarserver/tools/util.py
===================================================================
--- CalendarServer/trunk/calendarserver/tools/util.py	2013-04-19 17:26:34 UTC (rev 11068)
+++ CalendarServer/trunk/calendarserver/tools/util.py	2013-04-19 18:52:27 UTC (rev 11069)
@@ -462,7 +462,8 @@
     (yield action_removeProxyPrincipal(rootResource, directory, store,
         principal, proxyPrincipal, proxyTypes=proxyTypes))
 
-    yield scheduleNextGroupCachingUpdate(store, 0)
+    # Schedule in the past so the queue poller picks it up quickly
+    yield scheduleNextGroupCachingUpdate(store, -10*60)
 
 
 
@@ -495,7 +496,8 @@
         (yield subPrincipal.writeProperty(membersProperty, None))
 
     if removed:
-        yield scheduleNextGroupCachingUpdate(store, 0)
+        # Schedule in the past so the queue poller picks it up quickly
+        yield scheduleNextGroupCachingUpdate(store, -10*60)
     returnValue(removed)
 
 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20130419/2215be80/attachment-0001.html>


More information about the calendarserver-changes mailing list