Very similarly to the Expect Continue problem C# described here, HTTP POST Returns Error: 417 "Expectation Failed.", I was getting an "Expectation Failed" error from the server I was trying to POST to with a HttpPost object in Android.
Asked
Active
Viewed 5,647 times
1 Answers
16
The equivalent fix to prevent the request from using "expect continue" seems to be this:
httpPostInstance.getParams().setParameter(
CoreProtocolPNames.USE_EXPECT_CONTINUE,
Boolean.FALSE);
I found this at http://hc.apache.org/httpcomponents-client-ga/tutorial/html/fundamentals.html under 1.6.1.

Emre Yazici
- 10,136
- 6
- 48
- 55

Ivar Vong
- 201
- 2
- 7
-
Great work buddy. my expectation did not fail :). It continues. – N-JOY Jul 18 '13 at 19:42