users@jersey.java.net

Re: [Jersey] Client: Performance: InputStream fastest possibility?

From: Tatu Saloranta <tsaloranta_at_gmail.com>
Date: Sat, 18 Sep 2010 10:44:19 -0700

On Sat, Sep 18, 2010 at 10:18 AM, Johannes Schneider
<mailings_at_cedarsoft.com> wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Hi guys,
>
> at the moment I try to optimize some code that fetches a large JSON
> document. I am using the Client provided by Jersey.
>
> At the moment I am calling
>> resource.getEntity( InputStream.class )
>
> My profiler shows me, that the Jackson parser has to wait for the stream
> (in HttpInputStream#read) for a long time...

Sounds like maybe it is being buffered (read completely into in-memory
buffer) before being handed to Jackson?

-+ Tatu +-