Re: streaming request body

2004-02-25 Thread Ortwin Glück
John Keyes wrote: My point here is that if I have X requests then there can be X * CONTENT_LENGTH_CHUNKED bytes in memory at one time. I see what you mean. But the above calculation does not make sense: CONTENT_LENGTH_CHUNKED is a (negative) integer that signals to HttpClient that you do not

Re: streaming request body

2004-02-25 Thread John Keyes
On 25 Feb 2004, at 14:43, Ortwin Glück wrote: John Keyes wrote: My point here is that if I have X requests then there can be X * CONTENT_LENGTH_CHUNKED bytes in memory at one time. I see what you mean. But the above calculation does not make sense: CONTENT_LENGTH_CHUNKED is a (negative)

RE: streaming request body

2004-02-25 Thread Kalnichevski, Oleg
to implement based on our new preference architecture. Oleg -Original Message- From: John Keyes [mailto:[EMAIL PROTECTED] Sent: Wednesday, February 25, 2004 18:54 To: Commons HttpClient Project Subject: Re: streaming request body On 25 Feb 2004, at 14:43, Ortwin Glück wrote: John Keyes

Re: streaming request body

2004-02-24 Thread John Keyes
Keyes [mailto:[EMAIL PROTECTED] Sent: Monday, February 23, 2004 13:54 To: [EMAIL PROTECTED] Subject: streaming request body Hi, I notice you have separated out the functions of the connection and the content creation. So the code must be something like HttpClient client = new HttpClient( url

Re: streaming request body

2004-02-24 Thread Stefan Dingfelder
John Keyes schrieb: For (a), Oleg's response is correct. You might easily be confused, in the sense that HttpClient's API inverts the control. It is not that you write to an OutputStream to send your data, it is that you provide HttpClient with an InputStream, and it reads that stream and

Re: streaming request body

2004-02-24 Thread Ortwin Glück
John Keyes wrote: In both cases, it is possible to get the behavior that you desire. Not it is not. Again think of XXX,000 of requests. I am getting a little angry by now. C'mon man, we wrote this baby and we know very well what's possible with it. So please don't tell us it can not do

Re: streaming request body

2004-02-24 Thread Ortwin Glück
Stefan Dingfelder wrote: I am missing something here from both views. Maybe I am wrong but as I understand it, I can provide any InputStream. And that must not be a file on disk (which I dislike also - except for large files or live streams that cannot be put to memory in total) but can be any

RE: streaming request body

2004-02-24 Thread Kalnichevski, Oleg
Project Subject: Re: streaming request body For (a), Oleg's response is correct. You might easily be confused, in the sense that HttpClient's API inverts the control. It is not that you write to an OutputStream to send your data, it is that you provide HttpClient with an InputStream

Re: streaming request body

2004-02-24 Thread Eric Johnson
John Keyes wrote: For (a), Oleg's response is correct. You might easily be confused, in the sense that HttpClient's API inverts the control. It is not that you write to an OutputStream to send your data, it is that you provide HttpClient with an InputStream, and it reads that stream and sends

Re: streaming request body

2004-02-24 Thread John Keyes
On 24 Feb 2004, at 14:36, Stefan Dingfelder wrote: John Keyes schrieb: For (a), Oleg's response is correct. You might easily be confused, in the sense that HttpClient's API inverts the control. It is not that you write to an OutputStream to send your data, it is that you provide HttpClient

Re: streaming request body

2004-02-24 Thread John Keyes
On 24 Feb 2004, at 14:39, Ortwin Glück wrote: John Keyes wrote: In both cases, it is possible to get the behavior that you desire. Not it is not. Again think of XXX,000 of requests. I am getting a little angry by now. C'mon man, we wrote this baby and we know very well what's possible with it.

Re: streaming request body

2004-02-24 Thread John Keyes
lots_snipped/ Again, comments and feedback or a patch for bug 26070 would be welcome. Okay, I'll investigate it more and see what I come up with, -John K - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands,

Re: streaming request body

2004-02-24 Thread Stefan Dingfelder
Ortwin Glück schrieb: Stefan Dingfelder wrote: I am missing something here from both views. Maybe I am wrong but as I understand it, I can provide any InputStream. And that must not be a file on disk (which I dislike also - except for large files or live streams that cannot be put to memory

RE: streaming request body

2004-02-24 Thread Kalnichevski, Oleg
*concurrently*? What kind of application is it, if I may ask you? Oleg -Original Message- From: John Keyes [mailto:[EMAIL PROTECTED] Sent: Tuesday, February 24, 2004 16:59 To: Commons HttpClient Project Subject: Re: streaming request body On 24 Feb 2004, at 14:36, Stefan Dingfelder wrote: John

Re: streaming request body

2004-02-24 Thread Stefan Dingfelder
John Keyes schrieb: On 24 Feb 2004, at 14:39, Ortwin Glück wrote: John Keyes wrote: In both cases, it is possible to get the behavior that you desire. Not it is not. Again think of XXX,000 of requests. I am getting a little angry by now. C'mon man, we wrote this baby and we know very well

Re: streaming request body

2004-02-24 Thread John Keyes
to process around 70,000 requests a minute. -John K Oleg -Original Message- From: John Keyes [mailto:[EMAIL PROTECTED] Sent: Tuesday, February 24, 2004 16:59 To: Commons HttpClient Project Subject: Re: streaming request body On 24 Feb 2004, at 14:36, Stefan Dingfelder wrote: John Keyes

RE: streaming request body

2004-02-24 Thread Kalnichevski, Oleg
Subject: Re: streaming request body On 24 Feb 2004, at 16:22, Kalnichevski, Oleg wrote: But a *segment* will be held in memory prior to writing to the output stream though. For XXX,000 requests I think this is an unreasonable memory overhead. John, Just to make sure I understand you correctly

streaming request body

2004-02-23 Thread John Keyes
Hi, I notice you have separated out the functions of the connection and the content creation. So the code must be something like HttpClient client = new HttpClient( url ); HttpMethod method = new GetMethod(); method.setRequestHeader( ... ); ... method.setRequestBody( ... );

Re: streaming request body

2004-02-23 Thread Ortwin Glück
John Keyes wrote: method.setRequestBody( ... ); client.execute( method ); So my question is, is there a way to stream the request body rather than having to store the request in memory prior to writing it on the wire. setRequestBody accepts an InputStream. You could use a piped stream to

RE: streaming request body

2004-02-23 Thread Kalnichevski, Oleg
Oleg -Original Message- From: John Keyes [mailto:[EMAIL PROTECTED] Sent: Monday, February 23, 2004 13:54 To: [EMAIL PROTECTED] Subject: streaming request body Hi, I notice you have separated out the functions of the connection and the content creation. So the code must be something

Re: streaming request body

2004-02-23 Thread John Keyes
-commons/ httpclient/src/examples/ChunkEncodedPost.java?content- type=text%2Fplainrev=1.4.2.1 Hope this helps Oleg -Original Message- From: John Keyes [mailto:[EMAIL PROTECTED] Sent: Monday, February 23, 2004 13:54 To: [EMAIL PROTECTED] Subject: streaming request body Hi, I notice you have

Re: streaming request body

2004-02-23 Thread John Keyes
/ChunkEncodedPost.java?content- type=text%2Fplainrev=1.4.2.1 Hope this helps Oleg -Original Message- From: John Keyes [mailto:[EMAIL PROTECTED] Sent: Monday, February 23, 2004 13:54 To: [EMAIL PROTECTED] Subject: streaming request body Hi, I notice you have separated out the functions

RE: streaming request body

2004-02-23 Thread Rezaei, Mohammad A.
Have a look here: http://nagoya.apache.org/bugzilla/show_bug.cgi?id=26070 Thanks Moh -Original Message- From: John Keyes [mailto:[EMAIL PROTECTED] Sent: Monday, February 23, 2004 3:49 PM To: Commons HttpClient Project Subject: Re: streaming request body Guys, A colleague pointed

Re: streaming request body

2004-02-23 Thread Eric Johnson
To: [EMAIL PROTECTED] Subject: streaming request body Hi, I notice you have separated out the functions of the connection and the content creation. So the code must be something like HttpClient client = new HttpClient( url ); HttpMethod method = new GetMethod(); method.setRequestHeader