What are the difference between SyncML and CalDAV?

5.6k views Asked by At

I wonder what are the difference between SyncML and CalDAV in terms of features, pros, and cons.

I'm trying to determine which technology to use in order to synchronize events/calendars between a web app and mobile devices. I need to handle conflicts and bi directional synchronization.

At first glance, CalDAV seems to be the most suitable for my needs but I'm not sure to know possibility drawbacks. SyncML is a standard but I read some posts on Oracle's blog which said CalDAV is better...

I know Google supports both but also provides ActiveSync (Exchange) which is a Microsoft technology as their main solution. I'm not interested in this way.

Cheers, William

3

There are 3 answers

1
William Durand On BEST ANSWER

Well, I can answer myself.

CalDAV

CalDAV is a protocol on top of WebDAV which is an extension of the HTTP protocol. CalDAV is described in RFC 4791. It uses iCalendar as data format. There are a lot of implementations.

About conflicts CalDAV uses the 409 Conflicts status code (HTTP 1.1). The client has to deal with this error code, as far as I know, iCal (the Mac client) just reverts local changes. Then, it's quite easy to define rules in the server to know what to do if there are conflicts, if you cannot solve one of them, then we just need to send a 409 status code.

As a standard, CalDAV is dedicated to manage calendar data, and there are a lot of clients.

Unfortunately, Android doesn't provide any native solution to use this protocol, actually it doesn't provide anything else than Exchange ActiveSync (used by Google). But there are tons of CalDAV clients on the Android Market.

iOS has a native support of CalDAV.

SyncML

Synchronization Mrkup Language is a platform-independent synchronization language to manage data, created by major companies like Nokia, IBM, … It's an open standard. It uses HTTP as transport and XML to describe information. There a various server implementations, Funambol is a well-know for instance.

SyncML describes seven synchronizations:

  • Two-way Sync: both server and client shares information about changes, but the client is the first which send changes;
  • Slow sync: the client sends all its data. The server determines a delta between its data and client's data, then the server sends this delta. It's often used on the first synchronization;
  • One-way sync, client only: the client sends changes to the server;
  • Refresh sync from client: the client sends all its data, the server sends all its data;
  • One-way sync, server only: the server sends changes to the client;
  • Refresh sync from server: the server sends all its data, the client replaces its data by server's data;
  • Server alerted sync: the server asks the client to start a given synchronization.

SyncML handles conflits on the server with a set of predefined rules like Updates mades on the Client always win, Updates mades on the Client always win, …

SyncML is dedicated to synchronize data but neither iOS nor Android support it. Nokia or Samsung smartphones seem to support this protocol, as well as Windows Phone 6.

So?

Microsoft Exchange ActiveSync is the best choice to support almost all smartphones, and heavy clients too. But, it's not an open standard, and it's commercial, and I didn't describe it for these reasons, just remember it.

About mobile Operating Systems:

  • Android doesn't support anything else than ActiveSync, but some good CalDAV clients exist;
  • iOS supports CalDAV but doesn't support SyncML, and as far as I know, there is no SyncML client for calendar data (Funambol provides a client for contacts);
  • Windows Phone 7 doesn't support anything else than ActiveSync;
  • RIM (BlackBerry) doesn't seem to support CalDAV but there are SyncML clients;
  • I'm not sure about other OS (like Bada, …).

In France, iOS represents 60% of the mobile market, and Android has 30%.

The best solution (at least for me), is to start by implementing a CalDAV server with a set of custom rules to handle conflicts, and then to implement a SyncML server to cover the rest of the market.

1
Will Chesterfield On

A couple questions to better address your query -

  1. Are you in control of the device clients, or must you rely on native clients on already-deployed devices?

  2. Are you in control of the sync server?

  3. Are you expecting to need to sync other types of data besides calendar events? NB: things like calendar attachments (e.g., contacts or files) count as "other types of data" for the purposes of this question.

  4. What level of complexity do you need to support? Recurring events, exceptions to recurring events, shared or collaborative calenders, users with multiple separate calendars (e.g., device calendar, an Outlook calendar, a Gmail calendar, etc)

  5. Are there specific desktop apps you need to sync with (e.g., Outlook/Exchange), or is this entirely cloud <-> device only?

1
d-fens_ On

android does support syncml - check the funambold sync app
at android-client_funambol (checkout the forum there, its quite active and try the snapshots for advanced capabilities)