You are viewing a plain text version of this content. The canonical link for it is here.
Posted to httpclient-users@hc.apache.org by spencer <sa...@yahoo.com> on 2009/06/21 02:25:03 UTC

Chunk encoding multipart post

Hi,
Is it possible to chunk encode a multipart post?  

I noticed that the multipart entity is not extending the AbstractHttpEntity (which lets you enable chunk encoding).  The the other entities (like InputStream Entity) do.  Is this on purpose or just work yet to be completed?

Thanks for your help!
Spencer



      

Re: Chunk encoding multipart post

Posted by Oleg Kalnichevski <ol...@apache.org>.
spencer wrote:
> Hi Oleg,
> Thanks for your reply.  This helps but I have a follow up question.  Is there a way to use input streams for a part/body?  Like InputStreamEntity in the non-multipart example.  Rather than file or string?  
> 

Spencer

InputStreamBody is what you want.

Oleg

> Spencer
> 
>  
> 
> 
> 
> 
> ________________________________
> From: Oleg Kalnichevski <ol...@apache.org>
> To: HttpClient User Discussion <ht...@hc.apache.org>
> Sent: Monday, June 22, 2009 6:48:51 AM
> Subject: Re: Chunk encoding multipart post
> 
> On Sat, Jun 20, 2009 at 05:25:03PM -0700, spencer wrote:
>> Hi,
>> Is it possible to chunk encode a multipart post?  
>>
>> I noticed that the multipart entity is not extending the AbstractHttpEntity (which lets you enable chunk encoding).  The the other entities (like InputStream Entity) do.  Is this on purpose or just work yet to be completed?
>>
>> Thanks for your help!
>> Spencer
>>
>>
> 
> Hi Spencer
> 
> HttpClient will automatically use chunk coding if length of any parts in a
> multipart message is unknown (negative). Does this answer your question?
> 
> Oleg
> 
> 
>>      
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: mailto:httpclient-users-unsubscribe@hc.apache.org
> For additional commands, e-mail: mailto:httpclient-users-help@hc.apache.org
> 
> 
>       


---------------------------------------------------------------------
To unsubscribe, e-mail: httpclient-users-unsubscribe@hc.apache.org
For additional commands, e-mail: httpclient-users-help@hc.apache.org


Re: Chunk encoding multipart post

Posted by spencer <sa...@yahoo.com>.
Hi Oleg,
Thanks for your reply.  This helps but I have a follow up question.  Is there a way to use input streams for a part/body?  Like InputStreamEntity in the non-multipart example.  Rather than file or string?  

Spencer

 




________________________________
From: Oleg Kalnichevski <ol...@apache.org>
To: HttpClient User Discussion <ht...@hc.apache.org>
Sent: Monday, June 22, 2009 6:48:51 AM
Subject: Re: Chunk encoding multipart post

On Sat, Jun 20, 2009 at 05:25:03PM -0700, spencer wrote:
> Hi,
> Is it possible to chunk encode a multipart post?  
> 
> I noticed that the multipart entity is not extending the AbstractHttpEntity (which lets you enable chunk encoding).  The the other entities (like InputStream Entity) do.  Is this on purpose or just work yet to be completed?
> 
> Thanks for your help!
> Spencer
> 
> 

Hi Spencer

HttpClient will automatically use chunk coding if length of any parts in a
multipart message is unknown (negative). Does this answer your question?

Oleg


> 
>      

---------------------------------------------------------------------
To unsubscribe, e-mail: mailto:httpclient-users-unsubscribe@hc.apache.org
For additional commands, e-mail: mailto:httpclient-users-help@hc.apache.org


      

Re: Chunk encoding multipart post

Posted by Oleg Kalnichevski <ol...@apache.org>.
On Sat, Jun 20, 2009 at 05:25:03PM -0700, spencer wrote:
> Hi,
> Is it possible to chunk encode a multipart post?  
> 
> I noticed that the multipart entity is not extending the AbstractHttpEntity (which lets you enable chunk encoding).  The the other entities (like InputStream Entity) do.  Is this on purpose or just work yet to be completed?
> 
> Thanks for your help!
> Spencer
> 
> 

Hi Spencer

HttpClient will automatically use chunk coding if length of any parts in a
multipart message is unknown (negative). Does this answer your question?

Oleg


> 
>       

---------------------------------------------------------------------
To unsubscribe, e-mail: httpclient-users-unsubscribe@hc.apache.org
For additional commands, e-mail: httpclient-users-help@hc.apache.org