rajtrivedi2001 / rest-client

Automatically exported from code.google.com/p/rest-client
Apache License 2.0
0 stars 0 forks source link

sending .bin file #93

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
How to send .bin file from RESTClient 2.3 using POST method?
what should I select for content-type and charset to send .bin file to the
server?

Original issue reported on code.google.com by pati...@gmail.com on 15 Sep 2009 at 10:47

GoogleCodeExporter commented 8 years ago
Sorry, this is not supported at the moment.

Original comment by subwiz on 18 Sep 2009 at 3:00

GoogleCodeExporter commented 8 years ago
I am trying to send HTTP1.1 post request to from RESTClient to my server. The 
request
consists of expected-header : 100 Continue and hence i am sending back the 
HTTP/1.1
100 CONTINUE with a blank line and in return the RESTClient is sending the body 
part
of the POST request for which I am sending 200 SUCCESS response and closing the 
tcp
connection after getting acknowledgement from RESTClient TCP layer.

Problem : At this point the RESTclient is throughing exception "Invalid 
response from
the server". Below are the responses used by me
"HTTP/1.1 100 CONTINUE\r\n\r\n";
"HTTP/1.1 200 SUCCESS\r\n Content-Type:text/plain\r\n\r\n";

Second response "SUCCESS" is working fine with GET request, so i do not feel 
there is
any problem with format of the http responses. Please help

Original comment by pati...@gmail.com on 23 Sep 2009 at 8:40

GoogleCodeExporter commented 8 years ago
Do u have a demo Servlet which generates such request? I can try that with 
RESTClient
and see if this is an issue in RESTClient or the underlying HTTP Client library.

Original comment by subwiz on 16 Oct 2009 at 4:25

GoogleCodeExporter commented 8 years ago
r444 has the changes to accomodate binary body. This is the start. Lots more 
work to do 
to bring it to a good shape :-)

Original comment by subwiz on 21 Oct 2009 at 4:49

GoogleCodeExporter commented 8 years ago
The branch where I was working on binary body support became too unstable, and 
I had to remove the support. Marking this issue once again as New.

Original comment by subwiz on 22 Jul 2012 at 6:56

GoogleCodeExporter commented 8 years ago
Fixed in trunk. The trunk build is NO longer backward compatible with older 
version format.

Original comment by subwiz on 10 Aug 2012 at 5:25