Connect. Communicate. Collaborate. Securely.

Home » Kerio User Forums » Kerio Connect » Slow CalDAV-Interface

Messages: 15
Karma: 0
Send a private message to this user
I am accessing KerioConnnec's calendar server via http REPORT requests to receive calendar date for a certain user.
The calendar data the will be parsed ba my application and will be output as HTML thus creating a very simple read-only overview page.

This works pretty fine so far, but the more events are recorded with the calendar, the slower my caldav-requests get:

What I'm doing is something like this:
Issue an HTTP request with this header

REPORT /ical/ HTTP/1.1
Accept: */*
Accept-Language: en
Connection: Close
Authorization: Basic xxxxxxxxxxxxxxxxx=
User-Agent: PHP-requester
Depth: 1
Content-Type: application/xml; charset="utf-8"
Content-Length: 529

Request body:

<?xml version="1.0" encoding="utf-8" ?>
<C:calendar-query xmlns:D="DAV:"
<C:comp name="VCALENDAR">
<C:prop name="VERSION"/>
<C:comp name="VEVENT">
<C:comp-filter name="VCALENDAR">
<C:comp-filter name="VEVENT">
<C:time-range start="20140810T000000Z" end="20140816T000000Z"/>

As you can see, I do request the VEVENT items for one single week.
Well, as said, this works fine so far with the exeption of the http-request get slower and slower over time.
When we started to use the calendar, that is, with only very few events contained in it, response time was about a second or so.
Now, after having used the calendar for about a year or so, response time have slowed down to about 10 - 12 seconds, which my
users find hard to tolerate.
I'm afraid it will become even worse in the future.

Does anyone have an idea how to speed things up?

I have examined the KerioConnect-API for PHP (my application is written in PHP and runs on an intranet server)
but as far as I can see, it doesn't support REPORT http-requests, so this doesn't seem to be an option.

Interestingly enough, there seems to be a kind of internal cache within KerioConnect since once one has issued one successful request to the server the following ones (e.g. if the user reloads the page or pages through next/previous week) the response-time is a fast as about 0.4 seconds, but after a small time, the cache seems to invalidate and the again the next query again takes 10 or 12 seconds.

Oops, forgot to mention: This is
Kerio Connect 8.3.1 (2843)
Operating system:
Mac OS X Server (10.7.5), x86_64 (MacPro Server)

[Updated on: Mon, 11 August 2014 11:57]


Messages: 15
Karma: 0
Send a private message to this user
OK, since nobody did offer any clue to speed up the REPORT requests, I came up with a kind of solution for myself:

What I now do is caching the answers Kerio's CalDAV interface provides.

To do so I first query the CTag from Kerio with somthing like this:
<?xml version="1.0" encoding="utf-8" ?>
<d:propfind xmlns:d="DAV:" xmlns:c="">
    	<c:getctag />

and compare the value to the previous one stored in a local database. If the CTags differ, then someone has editeted the calendar an I do re-fetch the data from Kerio as described in my previous posting.
I then store the data in my local database and delete any older entries. The current CTag gets stored as well.

By using this sceme we only face lengthy delays the first time my HTML-view is displayed after en edit of the calendar data.

Although this solution is far from perfect, it provides a noticable speedup for cache hits which occurs at an average 50 to 1 ratio.
However Kerio's CalDAV interface keeps getting slower and slower the more data is collected within the calendar and its foreseeable to exceed my PHP's max_execution_time
Previous Topic: Mail sending under Yosemite slower?!?
Next Topic: how to backup user mailbox in kerio
Goto Forum:

Kerio discussion forums are intended for open communication between forum members and may contain information and material posted by members which may be useful in learning about Kerio products. The discussion forums are not intended to provide technical support for any specific product. Any information implied or expressed in the discussion forums is that of the posting member. Kerio is in no way responsible for the information posted in the forums, or its accuracy. Kerio employees may participate in the discussions, but their postings do not represent an offical position of the company on any issues raised or discussed. Kerio reserves the right to monitor and maintain the forums to promote free and accurate exchange of information.

Current Time: Wed Jan 18 23:17:36 CET 2017

Total time taken to generate the page: 0.01117 seconds
.:: Contact :: Home ::.
Powered by: FUDforum 3.0.4.