GSoC week 1-2 wrap up

Ok, time to write a bit about my progress in the first two GSoC coding weeks. So far, the foundations are laid out, I finally decided which SyncML implementation to use and how to realize what I plan. En plus, some code already hit playground 😉

First of all I decided to go for libsyncml as my backend. The two other competitors (Funambol C++ client SDK and libsynthesis) either don’t have all the required features (SyncML server mode, OBEX transport) or are difficult to handle from my POV. I did a rather lengthy review for myself and decided that this is the right way to go, even if libsyncml does have some issues here and there.

Before I’d like to go into further details, I’d like to revise what I’d like to achieve:

  • Being able to sync my mobile against Akonadi
  • Being able to let Akonadi sync against others
  • Configure all that in a comfortable way (don’t mess to much with SyncML)
  • Have it automated (where possible)

Being able to allow a mobile device to sync with my desktop’s Akonadi instance effectively means running a SyncML server to which the device can connect to and which interfaces with Akonadi itself.

Therefore we need a “Akonadi SyncML server agent”:

syncml_server_agent_1

And the corresponding configuration interface:

syncml_server_agent_2

There you can set how you want to expose SyncML functionality and what resources you want to be sync-able. Some advanced SyncML stuff is also there to help with all the beasty devices out there (more than you might think). As you can see, right know only one server instance is allowed to run at the same time, but this might change in the near future. For example you might want to have one OBEX / TCP server which exposes all your contact resources for your mobile and another one via HTTP which exposes each and every resource available for another Akonadi instance (I’ll come to that in a moment). Even more so, you might want to set some proper SSL encryption your HTTP setup but not necessarily for the mobile device (we’re all lazy aren’t we?).

Depending on what you are up to you might want to let your Akonadi instance behave like a client, e.g. let it go knocking on some web services (myFunambol.com, ScheduleWorld, Google stuff, etc.) or another Akonadi instance. And you don’t want to do that by yourself all the time. So we need a “Akonadi SyncML client agent” to do exactly that. Here’s the config screen draft:

syncml_client_agent_1

syncml_client_agent_2

This is where you can set how to access the remote server and again, what Akonadi resources you want to have synced. You also have to set some SyncML-specifica to access calendars and contacts on the remote partner. As you can see here, SyncML clients should be able do their job in different ways. You might want to have one client which syncs weekly with your google calender and you might want to have one client on your laptop which syncs with your desktop’s Akonadi instance upon network discovery (help, please!!).

And to be able to configure all that stuff without getting lost, we’ll need a KCM module. A profile concept remains to be elaborated to hide away all the complexity (more in a follow-up post).

Some code can already be found under playground/pim/syncml but you need a pretty recent version of libsyncml and libwbxml to get this to work. You can also fetch those dependencies with some patches applied from my SUSE-BuildService repository for several RPM-based distros:

http://download.opensuse.org/repositories/home:/saschpe/

33 thoughts on “GSoC week 1-2 wrap up

  1. Hi! This is very cool stuff. I have a few questions, though. How does this integrate with projects like opensync, synce, or kmobiletools? It would be really nice to have a pan-protocol framework to sinchronize ankonadi with other devices/dsktops/gadgets/etc. Anyway. This is a very good work. I hope you/someone can make debian packages of this stuff so impatient people like me can give it a try and get you real world info.

  2. Opensync is the main user of libsyncml, SyncE (for Microsoft ActiveSync) might be a future option for another way of syncing, however this has to be done then through other agents as the ones I’m creating right now would become to complex. At least the user interface (KCM or whatever) could integrate SyncML and SyncE stuff. I have no idea about the current status of kmobiletools. The later interacts with phones through AT commands, so it’s a different story.

  3. @Moult: As long as Windows Mobile 6 is SyncML-capable you won’t have problems with your device, altough I pretty much doubt that. Microsoft has it’s own technology called ActiveSync and nowadays a successor dubbed Windows Mobile Device something … Anyway, you might be lucky enough to find an SyncML application for your phone. Hope that clarifies a bit…

  4. When finished will I be able to sync my Nokia phone (E51) with KDE calander and contacts using Bluetooth or cable, or do I need to make the sync over a server?

    Syncing my calander and contacts are the last thing that keep me using Outlook (Yes it sucks 😉

    Thank you for you work!

  5. […] da es anscheinend aktuellen Trunk vorrausetzt. Aber hier ein paar Bilder von den ui-Dateien. Für genauere Informationen lest bitte Saschas Blog. #gallery-1 { margin: auto; } #gallery-1 .gallery-item { float: left; margin-top: 10px; text-align: […]

  6. Damn, everybody is waiting for finishing this project! Good job! OpenSync has been a pain in the ass for too long.

    Because it’s a GSoC, will you be able to finish the client this season?

  7. Great to see this coming along. I like your concept, looks very promising. Autosync on Device Connect, etc.
    I have one wish though, could you offer an option to limit the sync to a specific category? I.e. I have over 300 contacts in Kontact and don’t want them all on my mobile phone. Just the ones with category “mobile”. I guess the same principle could apply to calender data, etc…
    Keep on rocking! Looking forward to enjoy the fruits of your hard work. You get at least one free beer (even one free as in freedom) once this thing works for me!

  8. bloody cool stuff!!!! keep on coding 🙂 for me, syncml is the way to go…

  9. One more question! Are all these screenshots already pluged in or just stubs?

  10. I’ve been waiting for something like this for so damn long.. Please get this working 😀

  11. “* Being able to let Akonadi sync against others”

    Does this mean, I could be able to synchronize my akonadi address book with my syncML server (www.horde.org)? I would be glad to test this particular use case for you! (goliath23 on freenode)

  12. I’m pleased to hear of this project; I’m waiting for long time to sync my mobile phone.
    Thanks a lot for you’re work

  13. Hello,
    because I would really like to see this project working, I’ve build a small ebuild for my Gentoo.
    Now I’m syncing your svn and trying to build. But your FindFunambol.cmake is problematic for me as I can’t find the needed headers. It seems as they are not included neither in the funambol.org/svn nor in the funambol-forge-src-8.0.0.zip. Am I blind or just stupid?
    Regards pvm

  14. building/installing funambol is not that straightforward. the important headers can be found under

    $FUNAMBOL/sdk/cpp/src/include/common
    $FUNAMBOL/sdk/cpp/src/include/posix

    just install them like this:

    /usr/include/funambol/common
    /usr/include/funambol/posix

  15. Hallo Sascha, ich habe sowohl die Funambol Client-Library installiert und damit das SVN von akunambol ausgecheckt und auf meinem Testsystem intstalliert. Ich habe beim kompilieren und installieren keine Fehlermeldung bemerkt, allerdings erscheint der SyncML AGent nicht in Akonadi. Ich kann auf der Kommandozeile “akunambol” starten, dann erscheint ein Fenster und ich kann die Login-Daten eingeben sowie einen Button “Sync Contacts” drücken. Wo mein Funambol Server ist wird nicht abgefragt, auch finde ich nirgens die Maske wie hier im Blog weiter oben zu sehen. Hast Du einen Tipp, ob ich was vergessen habe bzw. wie ich das Plugin in Akonadi angezeigt bekomme, um es zu aktivieren und zu konfigurieren? Im Voraus vielen Dank!

  16. Akunambol ist ein anderes Playground-Projekt, welches IMHO nie über die Planungsphase hinausgekommen ist. Der SyncML Agent findet sich unter playground/pim/syncml. Eine etwas aktuellere Version findet sich im SyncEvolution Git-Repository.

  17. Hallo Sascha, vielen Dank für den Hinweis. libsyncml and libwbxml ist klar, leider finde ich keine git-URL für den SyncML Agenten. Ich habe zwar http://websvn.kde.org/trunk/playground/pim/syncml/ gefunden, leider bekomme ich das nicht per svn oder git auf meinen Rechner. Kannst Du bitte den checkout-Befehl mit URL für eine aktuelle Version des Akonadi-Agenten posten? Ich habe Kubuntu installiert, daher kann ich leider mit Deinen RPM-Paketen nichts anfangen.
    Vielen Dank!

  18. Hallo Sascha, vielen Dank für Deine Hilfe! Kompilieren hat einwandfrei geklappt, mit der Konfiguration klemmt es noch 😉 Wenn alles klappt, schreibe ich ein kleines howto für Kubuntu für Deinen Blog!

  19. Hallo Sascha, bin fast am Ziel 😉 Kompilieren hat geklappt, unter Kubuntu stimmen die Installationspfade für die diversen Konfigurationsdateien und Binaries nicht ganz. So weit ich es nachvollziehen konnte habe ich es umkopiert und entsprechend dokumentiert. Leider klappt es nicht ganz:
    Im KDE-Menü unter “Systemeinstellungen => Erweitert => SyncML” kann ich unter “Remote Sync Partner Profiles” einen neuen Profilnamen eingeben, das Profil erscheint dann auch in der Liste. Alle anderen Menüpunkte bleiben aber grau und lassen sich nicht benutzen. Wenn ich zurück zur Übersicht der Systemeinstellungen wechsele, stürzt Systemeinstellung ab. Im Log finde ich:
    operation=”file_perm” pid=2366 parent=2364 profile=”/usr/sbin/mysqld-akonadi” requested_mask=”::r” denied_mask=”::r” fsuid=1111 ouid=0 name=”/sys/devices/system/cpu/”
    drkonqi[2757]: segfault at 11 ip 01a4e950 sp bfe53fa0 error 6 in libkdecore.so.5.3.0[1985000+23d000]
    Zweites Problem (hängt evtl. damit zusammen): Im Akonadi Konfigurations Tool kann ich mit “Hinzufügen” problemlos den “SyncML Client Agent” auswählen und konfigurieren. Wenn ich das Konfigurationsfenster mit OK schließe, ist vom “SyncML Client Agent” in der Liste der Resourcen nichts zu sehen. Im Log finde ich auch nichts ;-( Ich vermute, dass einige Dateien noch nicht am richtigen Ort sind. Hast Du eine Idee, woran das liegen kann?
    Nochmals vielen Dank!

  20. @Michael: zum zweiten Problem: die SyncML-Agents tauchen nicht in der normalen Einrichtungsanzeige auf, aber in der akonadiconsole.

    Aber ich habe auch ein Problem: Ich habe funambol auf meinem Rechner installiert. Dort habe ich einen Nutzer eingerichtet und mein Handy (N900) kann sich erfolgreich damit synchronisieren. Dann habe ich in der akondaiconsole den SyncML-Client eingerichtet. Dieser taucht in der Liste mit der Bemerkung “Ready” auf. Der Status ist “online,idle”. Was muss ich jetzt machen? Der Button “Synchronize” macht gar nichts, auch wird in dem funambol kein device angelegt, so wie es für das Handy passiert ist. Was muss ich jetzt machen?

    Danke und Grüße
    Felix

  21. Hallo,
    ich stehe im Moment vor demgleichen Problem wie Michael. svn checkout klappt, kompilieren, installieren klappt, aber zur Laufzeit die oben von Michael beschriebenen Probleme (unter openSuSE11.2 mit KDE 4.4.2).

Comments are closed.