You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@camel.apache.org by PJ Walstroem <wa...@hotmail.com> on 2013/05/09 11:01:38 UTC

split an InputStream?

hello,
is it possible to use a splitter on an InputStream? I receive a big XML-file
via an HttpResponse.getEntity().getContent() and I have used SAX to parse
that stream and split it into smaller units. It works fairly well, but since
Camel has a split() which is designed to solve exactly that problem, I was
looking into using that instead. I can not load the complete XML into memory
beforehand, as the memory footprint would be huge.

any thoughts?

/pj



--
View this message in context: http://camel.465427.n5.nabble.com/split-an-InputStream-tp5732219.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Re: split an InputStream?

Posted by Claus Ibsen <cl...@gmail.com>.
Hi

See the links on this page about splitting big XML files
http://camel.apache.org/articles

On Thu, May 9, 2013 at 11:01 AM, PJ Walstroem <wa...@hotmail.com> wrote:
> hello,
> is it possible to use a splitter on an InputStream? I receive a big XML-file
> via an HttpResponse.getEntity().getContent() and I have used SAX to parse
> that stream and split it into smaller units. It works fairly well, but since
> Camel has a split() which is designed to solve exactly that problem, I was
> looking into using that instead. I can not load the complete XML into memory
> beforehand, as the memory footprint would be huge.
>
> any thoughts?
>
> /pj
>
>
>
> --
> View this message in context: http://camel.465427.n5.nabble.com/split-an-InputStream-tp5732219.html
> Sent from the Camel - Users mailing list archive at Nabble.com.



-- 
Claus Ibsen
-----------------
Red Hat, Inc.
FuseSource is now part of Red Hat
Email: cibsen@redhat.com
Web: http://fusesource.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen