[CalendarServer-changes] [14374] CalendarServer/trunk
source_changes at macosforge.org
source_changes at macosforge.org
Thu Feb 5 12:10:28 PST 2015
Revision: 14374
http://trac.calendarserver.org//changeset/14374
Author: cdaboo at apple.com
Date: 2015-02-05 12:10:28 -0800 (Thu, 05 Feb 2015)
Log Message:
-----------
Fix for If-Schedule-Tag-Match behavior and splitting.
Modified Paths:
--------------
CalendarServer/trunk/requirements-dev.txt
CalendarServer/trunk/twistedcaldav/storebridge.py
Modified: CalendarServer/trunk/requirements-dev.txt
===================================================================
--- CalendarServer/trunk/requirements-dev.txt 2015-02-05 20:08:42 UTC (rev 14373)
+++ CalendarServer/trunk/requirements-dev.txt 2015-02-05 20:10:28 UTC (rev 14374)
@@ -8,4 +8,4 @@
q
tl.eggdeps
--editable svn+http://svn.calendarserver.org/repository/calendarserver/CalDAVClientLibrary/trunk@13420#egg=CalDAVClientLibrary
---editable svn+http://svn.calendarserver.org/repository/calendarserver/CalDAVTester/trunk@14366#egg=CalDAVTester
+--editable svn+http://svn.calendarserver.org/repository/calendarserver/CalDAVTester/trunk@14373#egg=CalDAVTester
Modified: CalendarServer/trunk/twistedcaldav/storebridge.py
===================================================================
--- CalendarServer/trunk/twistedcaldav/storebridge.py 2015-02-05 20:08:42 UTC (rev 14373)
+++ CalendarServer/trunk/twistedcaldav/storebridge.py 2015-02-05 20:10:28 UTC (rev 14374)
@@ -2982,6 +2982,16 @@
if not self.exists():
raise HTTPError(NOT_FOUND)
+ # Do schedule tag check
+ try:
+ self.validIfScheduleMatch(request)
+ except HTTPError as e:
+ if e.response.code == responsecode.PRECONDITION_FAILED:
+ response = yield self._processPrefer(request, e.response)
+ raise HTTPError(response)
+ else:
+ raise
+
# Split point is in the rid query parameter
rid = request.args.get("rid")
if rid is None:
@@ -3029,6 +3039,8 @@
raise HTTPError(StatusResponse(responsecode.NOT_ACCEPTABLE, "Cannot generate requested data type"))
etag1 = yield self.etag()
etag2 = yield other.etag()
+ scheduletag1 = self.scheduleTag
+ scheduletag2 = otherStoreObject.scheduleTag
cal1 = yield self.component()
cal2 = yield other.component()
@@ -3038,6 +3050,7 @@
davxml.PropertyStatus(
davxml.PropertyContainer(
davxml.GETETag.fromString(etag1.generate()),
+ caldavxml.ScheduleTag.fromString(scheduletag1),
caldavxml.CalendarData.fromComponent(cal1, accepted_type),
),
davxml.Status.fromResponseCode(OK),
@@ -3048,6 +3061,7 @@
davxml.PropertyStatus(
davxml.PropertyContainer(
davxml.GETETag.fromString(etag2.generate()),
+ caldavxml.ScheduleTag.fromString(scheduletag2),
caldavxml.CalendarData.fromComponent(cal2, accepted_type),
),
davxml.Status.fromResponseCode(OK),
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20150205/004bda1e/attachment.html>
More information about the calendarserver-changes
mailing list