On Apr 18, 2014, at 10:57 PM, Ismail Yenigul <[email protected]> wrote: > We use the following REPORT query to get list of the events in personal > calendar. > > REPORT http://sogo-demo.inverse.ca/SOGo/dav/sogo3/Calendar/personal > > <?xml version="1.0" encoding="utf-8" ?><c:calendar-query xmlns:d="DAV:" > xmlns:c="urn:ietf:params:xml:ns:caldav"><d:prop><d:getetag /><c:calendar-data > /></d:prop><c:filter><c:comp-filter name="VCALENDAR"><c:comp-filter > name="VEVENT"/></c:comp-filter></c:filter></c:calendar-query>
This is extremely inefficient, don't do this with any server. You refetch the whole database on every sync?! Also, only filter if the supported-component-set of the collection supports anything but VEVENT. This will most of the time not be necessary (anymore). The common procedure for syncing a collection is: 1) fetch all etags of the collection (usually using PROPFIND or the calendar-query just for the etag, not calendar-data) 2) compare the etags against the cached etags 3) use a set of batched multiget REPORTs (if supported, otherwise individual GETs) to fetch just the resources which changed. Or alternatively, if the server supports it and the sync-token is still valid, do all this with sync-reports. I don't think SOGo supports sync reports, not sure. > Other DAV server returns the data correctly. But SOGo return the following > error: > > Response: > HTTP/1.1 400 Request Failed First: There is nothing wrong with you request, it's not malformed and perfectly valid CalDAV. File a SOGo bug report. Not sure what the right return code would be, but certainly not 400. Maybe 501 or some 403 with a proper DAV:error. Second: I think you get this error because SOGo simply doesn't support this specific query. Which is unnecessary in the first place, as AFAIK SOGo collections are single-type. hh -- [email protected] https://inverse.ca/sogo/lists
