Synthesis AG - SyncML Discussion Forum

Synthesis AG - SyncML Discussion Forum (http://forum.synthesis.ch/index.php)
-   Other SyncML clients (Sunbird, Outlook beta, Console, etc.) (http://forum.synthesis.ch/forumdisplay.php?f=7)
-   -   Request slow sync (http://forum.synthesis.ch/showthread.php?t=1444)

zijian 2008-06-19 22:28

Request slow sync
 
I am developing SyncML.NET Client API which has been working fine with Funambol, now I am testing with Synthesis.

After successful b64 authentication with the server, the client requests slow sync with the following:
<SyncML>
<SyncHdr>
<VerDTD>1.2</VerDTD>
<VerProto>SyncML/1.2</VerProto>
<SessionID>20053948</SessionID>
<MsgID>2</MsgID>
<Target>
<LocURI>https://www.synthesis.ch/sync?sessionid=6556959586774370394</LocURI>
</Target>
<Source>
<LocURI>OpenContactsGuid</LocURI>
</Source>
</SyncHdr>
<SyncBody>
<Status>
<CmdID>1</CmdID>
<MsgRef>1</MsgRef>
<CmdRef>0</CmdRef>
<Cmd>SyncHdr</Cmd>
<TargetRef>https://www.synthesis.ch/sync</TargetRef>
<SourceRef>OpenContactsGuid</SourceRef>
<Data>200</Data>
</Status>
<Alert>
<CmdID>2</CmdID>
<Data>200</Data>
<Item>
<Target>
<LocURI>./contacts</LocURI>
</Target>
<Source>
<LocURI>localcontact</LocURI>
</Source>
<Meta>
<Anchor xmlns='syncml:metinf'>
<Last xmlns='syncml:metinf'>0</Last>
<Next xmlns='syncml:metinf'>1</Next>
</Anchor>
</Meta>
</Item>
</Alert>
<Final/>
</SyncBody>
</SyncML>


The the server refuses with the following:
<?xml version="1.0" encoding="UTF-8"?>
<SyncML xmlns='SYNCML:SYNCML1.2'>
<SyncHdr>
<VerDTD>1.2</VerDTD>
<VerProto>SyncML/1.2</VerProto>
<SessionID>20053948</SessionID>
<MsgID>2</MsgID>
<Target>
<LocURI>OpenContactsGuid</LocURI>
</Target>
<Source>
<LocURI>https://www.synthesis.ch/sync?sessionid=6556959586774370394</LocURI>
</Source>
<Meta>
<MaxMsgSize xmlns='syncml:metinf'>50000</MaxMsgSize>
<MaxObjSize xmlns='syncml:metinf'>4000000</MaxObjSize>
</Meta>
</SyncHdr>
<SyncBody>
<Status>
<CmdID>1</CmdID>
<MsgRef>2</MsgRef>
<CmdRef>0</CmdRef>
<Cmd>SyncHdr</Cmd>
<TargetRef>https://www.synthesis.ch/sync?sessionid=6556959586774370394</TargetRef>
<SourceRef>OpenContactsGuid</SourceRef>
<Data>200</Data>
</Status>
<Status>
<CmdID>2</CmdID>
<MsgRef>2</MsgRef>
<CmdRef>2</CmdRef>
<Cmd>Alert</Cmd>
<TargetRef>./contacts</TargetRef>
<SourceRef>localcontact</SourceRef>
<Data>403</Data>
<Item>
<Data>Sync Alert only allowed in init package</Data>
</Item>
</Status>
<Final/>
</SyncBody>
</SyncML>

I noticed the explanation from the server: Sync Alert only allowed in init package. And I understand in SyncML specification it is allowed the send sync alert in init package.

However, my client program does not have assumption of what the data store is for the contacts. Through the init package, it obtains the location of contact data store through reading the device info sent back by the server like this one:
<DataStore>
<SourceRef>./contacts</SourceRef>
<DisplayName>contacts</DisplayName>
<Rx-Pref>
<CTType>text/x-vcard</CTType>
<VerCT>2.1</VerCT>
</Rx-Pref>

For example, in Funambol, SourceRef is card or scard.
Then send sync request with correct location of data store.

A workaround could be that the client program would connect to the server first to obtain device info, then re-connect or re-logon to send the sync alert in the Init package. But it seems redundant to send credential twice.

Do you have any idea whether the separation of init and sync alert could be possible in Synthesis?


All times are GMT +2. The time now is 03:24.

Powered by vBulletin® Version 3.7.0
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.