Antwort: Re: [xsd-users] CodeSythesis XSD - CXX Tree Multithreading issue

tomislav.reichenbach at valida.at tomislav.reichenbach at valida.at
Fri Mar 9 03:36:42 EST 2012


Hi Boris,

> Von: boris at codesynthesis.com
> An: tomislav.reichenbach at valida.at
> Kopie: xsd-users at codesynthesis.com
> Datum: 07.03.2012 11:31
> Betreff: Re: [xsd-users] CodeSythesis XSD - CXX Tree Multithreading 
issue
> 
> Hi Tom,
> 
> tomislav.reichenbach at valida.at <tomislav.reichenbach at valida.at> writes:
> 
> > > By "the error occurs" do you mean that an exception is thrown? Or 
does
> > > the thread complete without any errors but the written XML is 
incomplete?
> > 
> > I get both, roughly ..
> > 
> > ... 30% of return happens with an exception thrown, unfortunatelly the 
one
> > I cannot catch with all FAQ catch variants, only with catch(...).
> > 
> > ... 60% of return have incomplete XML (no exception is thrown)
> > 
> > ... 10% have correct return XML
> 
> Hm, this is very strange. Do you catch all the exceptions, including
> the Xerces-C++ ones? If that's the case, then chances are high this
> is an access violation exception (will also explain why you sometimes
> get just the incorrect behavior without an exception).
> 
> Ideally, you would want to run this application under a debugger (or
> let it crash and then load it into the debugger to examine the stack
> trace) to figure out what kind of exception it is.
> 

Yep. That was basically the part where I stopped, and decided to contact 
codesythesis dev team ;)

As I saw it there were two possible options.

The problem is I have to run it on server. I cannot reproduce it manually.
This involves modifying build script and CI server deployment process to 
deploy it
remotely on the server and then trying with remote debugger (which leads 
to asking our IT
support for the remote debugging installation and permissions) :|
There was no need prior to debug remotely so this setup is something I'm 
doing right now ...
(Also today I got a new dev PC - core i5 - so I'm gonna try to reproduce 
it locally).

The other thing I'm trying is to catch all exceptions (via SEH) and try to 
log them.

As I said, I'm 100% sure the error is in the serialization. Also what is 
left to try is to try the Xerces directly,
as you suggested.

Unfortunately, I have to do some other stuff, so I can't dedicate a lot to 
this problem, but I hope in next
few days to try the above mentioned approaches.

> 
> > Input and output have different structure. Calculation function
> > instantiates new output objects. (Input size is 5KB vs Output size
> > of 1585KB)
> > 
> > [...]
> > 
> > I can make the modifications, and I will try to implement them and
> > report the outcome.
> 
> You could change your code to send the output XML as input. Then parse
> it to DOM and serialize it back to XML.
> 

btw.. Compliments on your blog !

regards,

Tom



More information about the xsd-users mailing list