[dev] Exposing timeobjects to caldav

Ralf Lang lang at b1-systems.de
Wed Aug 16 16:44:53 UTC 2017


On 15.08.2017 20:53, Jan Schneider wrote:
> 
> Zitat von Ralf Lang <lang at b1-systems.de>:
> 
>> On 13.08.2017 19:01, Ralf Lang wrote:

I need to craft UIDs to make birthdays from turba work.

$ical->addComponent($event->toiCalendar($ical)) seems to trigger a very 
deep recursion for birthdays - Events with start date and yearly 
recursion, but no real end (in data, at least). But only from turba, not 
for kronolith native events.

How to reproduce:

$app = Horde_Registry::appInit('kronolith');

$driver = Kronolith::getDriver('Horde', 
'contacts/birthday/13Q5VRmDqoeMFBOHEJKk5h_');

$event = $driver->getEvent('_contactstbNyQSp4mS7WJTB7hMqDWs7');
$event->loadHistory();
print_r($event);
$ical = new Horde_Icalendar('2.0');

$icalEvent = $event->toiCalendar($ical);

-> looooong and deep recursion until oom.


This is probably because the "Horde" Driver does not provide uid's for 
its events.

http://www.kanzaki.com/docs/ical/uid.html

Looking at the DB, I have long (113 chars) hex strings, uuids, and 
uuid at host formats as well as strings like KOrganizer-Something.

Using event->calendar @ $event->id would produce

contacts/birthday/13Q5VRmDqoeMFBOHEJKk5h_ at _contactstbNyQSp4mS7WJTB7hMqDWs7

which looks about as unique as a native kronolith uid.

However I am not sure if any app would present the same timeobject using 
the same id differently to different users. I don't think so.



-- 
Ralf Lang
Linux Consultant / Developer
Tel.: +49-170-6381563
Mail: lang at b1-systems.de
B1 Systems GmbH
Osterfeldstraße 7 / 85088 Vohburg / http://www.b1-systems.de
GF: Ralph Dehner / Unternehmenssitz: Vohburg / AG: Ingolstadt,HRB 3537


More information about the dev mailing list