|
From: deloptes <del...@ya...> - 2010-09-19 09:49:57
|
To summarize:
The plugin in discover will iterate over the akonadi resources and will
check for "known" resources. If it finds something that is not provided in
the config (but supported) it will be written into the config. The user may
change it after the discover step.
For me it is easier to skip the iteration over the configured items in
discover and use
if ( ... ) { //check for calendars
res = osync_plugin_config_find_active_resource(config,"event");
if (! res)
res = osync_plugin_resource_new( error );
... //use the resource
}
Which makes, in my opinion, the config optional for discovering supported
types (if it is not listed in the config it will be created on the fly
after matching one of the types the plugin supports.
So I am planing to keep the original config with "contact" and "event" in it
and let the plugin put the rest. I need more information on how to
implement the solution with the multiple resources in the other sub thread.
Something I found about akonadi is that if you configure address book or
calendar you have to explicitly enable them as ressource in akonadi. After
this they are reported back.
akonadi_opensync(10606) akonadi_discover: using resource contact
for "Address Book" ("text/directory", "application/x-vnd.kde.contactgroup")
akonadi_opensync(10606) akonadi_discover: using resource for
calendar: "Calendar"
("text/calendar", "application/x-vnd.akonadi.calendar.event",
"application/x-vnd.akonadi.calendar.todo", "application/x-vnd.akonadi.calendar.journal",
"application/x-vnd.akonadi.calendar.freebusy")
akonadi_opensync(10606) akonadi_discover: using resource for
note: "akonadi_notes_resource_1" ("application/x-vnd.kde.notes")
akonadi_opensync(10606) akonadi_finalize:
Discovered Objtypes:
Address Book
No formats found: (null)
Calendar
No formats found: (null)
akonadi_notes_resource_1
No formats found: (null)
I think now I have much better understanding
thanks
|