On Thu July 9 2009 11:24:53 am xinxinwang wrote:
> I have a question regarding the SAXSource. If a web service uses Source
> mode with SAXSource, will the returned data be sent back to the client in a
> streaming way?

It depends on a couple things:   :-)

1) Version of CXF - DEFINITELY use 2.2.1 or newer (2.2.2 is current).  Prior 
versions would not have streamed it properly.

2) JAX-WS handlers - don't use them.  The JAX-WS handler APIs require a SAAJ 
SOAPMessage which would put the whole thing in memory.   If there are no SAAJ 
handlers we can stream.

3) Likewise, WS-Security related things require the full SAAJ model.

> If the data is very large, do I still need to worry about
> the memory usage if using SAXSource?

For the most part, using "normal" things, you won't need to worry.   The 
result will stream back fine.    

-- 
Daniel Kulp
[email protected]
http://www.dankulp.com/blog
  • SAXSource xinxinwang
    • Re: SAXSource Daniel Kulp

Reply via email to