Hi Oli,
 
I think the big question is if the any type is good choice for an arbitrary 
message. For example the message could contain invalid xml that will make your 
whole webservice call invalid. So I propose to either base 64 encode the 
original message or send it as a MTOM attachment. In these cases you probably 
will not need to cope with a dom tree anyway.

The big disadvantage of course is that the resulting call is not nicely 
readable anymore.

Best Regards

Christian



Christian Schneider
Informationsverarbeitung 
Business Solutions
Handel und Dispatching

Tel : +49-(0)721-63-15482

EnBW Systeme Infrastruktur Support GmbH
Sitz der Gesellschaft: Karlsruhe
Handelsregister: Amtsgericht Mannheim ­ HRB 108550
Vorsitzender des Aufsichtsrats: Dr. Bernhard Beck
Geschäftsführer: Jochen Adenau, Hans-Günther Meier


-----Ursprüngliche Nachricht-----
Von: Oliver Wulff [mailto:[email protected]] 
Gesendet: Freitag, 12. November 2010 08:07
An: [email protected]
Betreff: Fill element of type any without parsing the xml document in advance

Hi all



A web service provider has deployed an interceptor which should log the 
incoming message in a similar performant way as the logging interceptor but not 
into a file. Instead the incoming message is sent as part of a web service call 
with other monitoring related information. The message is passed as an any type.



I want to avoid that a DOM tree is created when filling the any type. I have to 
make a copy of the message because the message is sent in a seperated thread 
(scheduler) to not block processing of the incoming request.



I wanted to copy the stream into a string which can be read by the scheduler. 
But I haven't found a way to write the xml content of the cached string into 
the xml any.



Any hints are highly appreciated.



Thanks

Oli

Reply via email to