logo       

vCard parser failure in 3.0 Funambol server and handling of failure (was: R: msg#00154

java.sync4j.user

Subject: vCard parser failure in 3.0 Funambol server and handling of failure (was: Re: Cingular 8525 Pocket Outlook sync with Evolution)

On Tue, 2007-02-06 at 23:51 +0100, Patrick Ohly wrote:
> Here it complains about pas-id-4227CE8100000003, but not in a way that
> is directly associated with that item. Therefore we do not get the
> error
> message out of syncevolution that I expected.
>
> It remains a mystery why the server rejects your contacts. Your
> configuration looks okay (type text/x-vcard and URI card).

James solved the problem by deleting old contacts, but now I ran into
the same issue. In my case the server complains about (manually edited
to anonymize it):

<Data><![CDATA[BEGIN:VCARD
VERSION:2.1
REV:2007-02-03T17:06:53Z
UID:pas-id-45C4C12D000000C8
N:foo;bar;;;
FN:Bar Foo
EMAIL;TYPE=INTERNET:xxx@xxxxxxx
X-EVOLUTION-FILE-AS:Foo, Bar
X-WSS-LUID:BOcDONnGfNtG/NDlk2J5BA==
END:VCARD
]]></Data>


[20.02.2007 22:46:10][funambol.engine.strategy] SEVERE: Error retrieving
the twin item of { keyValue: pas-id-45C4C12D000000C8 } from source
com.funambol.foundation.engine.source.SIFVCardSyncSource@9b1670 - {name:
card, type:
text/x-vcard, uri: card} - { name: card,
sourceDirectory: ../../../ds-server/db/contact }: Error parsing the
vCard pas-id-45C4C12D000000C8
[20.02.2007 22:46:10][funambol.engine.strategy] FINER: THROW
com.funambol.framework.engine.source.SyncSourceException: Error parsing
the vCard pas-id-45C4C12D000000C8
at
com.funambol.foundation.engine.source.SIFVCardSyncSource.getSyncItemKeysFromTwin(SIFVCardSyncSource.java:155)
at
com.funambol.server.engine.Sync4jStrategy.fixMappedItems(Sync4jStrategy.java:1292)
at
com.funambol.server.engine.Sync4jStrategy.prepareSlowSync(Sync4jStrategy.java:291)
at
com.funambol.server.engine.Sync4jEngine.sync(Sync4jEngine.java:539)
at
com.funambol.server.session.SyncSessionHandler.processModifications(SyncSessionHandler.java:1580)
at
com.funambol.server.session.SyncSessionHandler.processSyncMessage(SyncSessionHandler.java:1429)
at
com.funambol.server.session.SyncSessionHandler.processInitSyncMapMessage(SyncSessionHandler.java:870)
at
com.funambol.server.session.SyncSessionHandler.processMessage(SyncSessionHandler.java:459)
at
com.funambol.server.engine.SyncAdapter.processInputMessage(SyncAdapter.java:459)
at
com.funambol.server.engine.SyncAdapter.processXMLMessage(SyncAdapter.java:215)
at
com.funambol.transport.http.server.LocalSyncHolder.processXMLMessage(LocalSyncHolder.java:80)
at
com.funambol.transport.http.server.Sync4jServlet.doPost(Sync4jServlet.java:297)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214)
at
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
a:520)
at
org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:198)
at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:152)
at
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:137)
at
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:118)
at
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:102)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at
org.apache.catalina.core.StandardValveContext.invokeNext(StandardValveContext.java:104)
at
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:520)
at
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:929)
at
org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:160)
at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:799)
at org.apache.coyote.http11.Http11Protocol
$Http11ConnectionHandler.processConnection(Http11Protocol.java:705)
at
org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:577)
at org.apache.tomcat.util.threads.ThreadPool
$ControlRunnable.run(ThreadPool.java:684)
at java.lang.Thread.run(Unknown Source)
Caused by: com.funambol.foundation.pdi.parser.ParseException:
Encountered "<EOF>" at line 10, column 12.
Was expecting one of:
"CATEGORIES" ...
"VERSION" ...
"TITLE" ...
"NICKNAME" ...
"EMAIL" ...
"FN" ...
"ORG" ...
"BDAY" ...
"PHOTO" ...
"ADR" ...
"UID" ...
"LABEL" ...
"ROLE" ...
"TZ" ...
"LOGO" ...
"NOTE" ...
"URL" ...
"N" ...
"REV" ...
"TEL" ...
<VCEND> ...
<EXTENSION> ...
<IDENTIFIER> ...

at
com.funambol.foundation.pdi.parser.VcardParser.generateParseException(VcardParser.java:2104)
at
com.funambol.foundation.pdi.parser.VcardParser.jj_consume_token(VcardParser.java:1984)
at
com.funambol.foundation.pdi.parser.VcardParser.vCard(VcardParser.java:394)
at
com.funambol.foundation.pdi.parser.VcardParser.vCard(VcardParser.java:339)
at
com.funambol.foundation.engine.source.SIFVCardSyncSource.getSyncItemKeysFromTwin(SIFVCardSyncSource.java:140)
... 37 more

[20.02.2007 22:46:10][funambol.handler] FINEST: responseCommands:
[com.funambol.framework.core.Status@1de4dd8,
com.funambol.framework.core.Sync@1c8b24d]
[20.02.2007 22:46:10][funambol.engine] FINEST: Saving client mapping:
com.funambol.framework.server.ClientMapping@1320a41[clientMapping=[],modifiedKeys=[],deletedKeys=[0,
1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 14, 15, 16, 17,
18, 19, 20, 21, 22, 23, 24, 13, 25, 26, 27]]
[20.02.2007 22:46:10][funambol.handler] FINEST: Checking if MaxMsgSize
is larger than the minimum size supported by the server (2500)
[20.02.2007 22:46:10][funambol.server] FINEST: Using the request url to
create the RespURI
[20.02.2007 22:46:10][funambol.server] FINEST: Calling output pipeline
[20.02.2007 22:46:10][funambol.engine.pipeline] FINEST: Starting
postprocessing
[20.02.2007 22:46:10][funambol.engine.pipeline] FINEST: Returning
message to process: <?xml version="1.0" encoding="UTF-8"?>
<SyncML>
<SyncHdr>
<VerDTD>1.1</VerDTD>
<VerProto>SyncML/1.1</VerProto>
<SessionID>1172007967</SessionID>
<MsgID>3</MsgID>
<Target>
<LocURI>sc-api-nat</LocURI>
</Target>
<Source>
<LocURI>http://localhost:8080/funambol/ds</LocURI>
</Source>
<RespURI>http://localhost:8080/funambol/ds;jsessionid=3C05D87029567EB776B1208641909F5E</RespURI>
</SyncHdr>
<SyncBody>
<Status>
<CmdID>1</CmdID>
<MsgRef>3</MsgRef>
<CmdRef>0</CmdRef>
<Cmd>SyncHdr</Cmd>
<TargetRef>http://localhost:8080/funambol/ds</TargetRef>
<SourceRef>sc-api-nat</SourceRef>
<Data>200</Data>
</Status>
<Status>
<CmdID>2</CmdID>
<MsgRef>3</MsgRef>
<CmdRef>3</CmdRef>
<Cmd>Sync</Cmd>
<TargetRef>card</TargetRef>
<SourceRef>addressbook_1</SourceRef>
<Data>506</Data>
<Item>
<Data>Error parsing the vCard pas-id-45C4C12D000000C8</Data>
</Item>
</Status>
</SyncBody>
</SyncML>

This is with the 3.0 Funambol server, running on Linux.

Two questions:
* Why does the server abort the sync instead of skipping the item?
It's not unlikely that the server will not be able to handle
everything that clients might send it; forcing users to figure
out which items break the sync one by one is not a very friendly
solution. IMHO the server should send a status back for the item
which indicates a failure and otherwise continue. Then the
client can report that and the user has a full list of all
broken items.
* Why is this particular item unacceptable? The
REV:2007-02-03T17:06:53Z looks a bit strange, but (without
checking the standard) I'd say that anything following the
first : is the value of the property and may contain further
colons.

--
Bye, Patrick Ohly
--
Patrick.Ohly@xxxxxx
http://www.estamos.de/

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV


<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise