users@jax-ws.java.net

Re: MTOM and SOAPHandler performance issue

From: <kristof.depraetere_at_agfa.com>
Date: Wed, 6 Dec 2006 09:42:30 +0100

Sergey,

Sniffing the connection indeed shows that the binary is inlined into the
SOAP message and no xop:Include is created. This explains why the
performance hit is so big.
So handlers and MTOM are not compatible for the moment?

Thanks for pointing it out.

Thanks,
Kristof.





Sergey Shepelevich <sergey_at_shepelevich.com>
06/12/2006 09:28
Please respond to Sergey Shepelevich
 
        To: Kristof Depraetere/AMOVL/AGFA_at_AGFA
        cc: users_at_jax-ws.dev.java.net
        Subject: Re: MTOM and SOAPHandler performance issue


Hi,

Are you sure you have MTOM working with handlers ? We have an issue with
it, when we add any header into SOAP message,
MTOM doesnt work. Looks like the new header is resetting MTOM and it stops
working.



>

Hi,

I use the SOAPHandler handler mechanism to add header information to the
SOAP message by my web service client.
However when MTOM is used to transfer large binaries (>3Mb) the
performance penalty is huge (300 times slower). Using MIME with
Attachments to transfer these binaries gives no performance impact in the
same scenario.

Apparently retrieving the SOAPPart from the messageContext is slow.

I use the following to add a header to the envelope:

        public boolean handleMessage(SOAPMessageContext messageContext) {
        // ...
        SOAPEnvelope envelope =
messageContext.getMessage().getSOAPPart().getEnvelope();
        SOAPHeader header = envelope.addHeader();
        //...
        }

I'm using 2.1EA3.

Any idea on how to speed this up?

Thanks,
Kristof




-- 
Thanks,
Bytex