[ 
https://issues.apache.org/jira/browse/JCLOUDS-181?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13706347#comment-13706347
 ] 

ASF subversion and git services commented on JCLOUDS-181:
---------------------------------------------------------

Commit 76e5e80e5bf0193bd492070ac9727e5a76de74b7 in branch refs/heads/1.6.x from 
[~diwaker]
[ https://git-wip-us.apache.org/repos/asf?p=incubator-jclouds.git;h=76e5e80 ]

Introduce StripExpectHeader filter and a property to control it.

Some providers (specifically HP Cloud and Google Cloud Storage) do not
properly support Expect: 100-continue headers. JDK7 is stricter in its
handling of the Expect header than JDK6 -- in particular, it expects
servers to properly respond to an expect header and times out only if a
prior timeout did not exist on the underlying HTTP connection. As a
result, JDK7 tests against these providers hang and fail.

This commit introduces a new filter -- appropriate called
StripExpectHeader -- that is controlled by the property
jclouds.strip-expect-header. The property defaults to false to preserve
existing behavior but allows applications to tweak Expect header
handling.

Tested by running HPCS live tests with JDK7 -- previously most of these
tests would fail with timeouts.

Closes JCLOUDS-181

                
> Blobstores that lack proper support for 100-Continue don't work with JDK7
> -------------------------------------------------------------------------
>
>                 Key: JCLOUDS-181
>                 URL: https://issues.apache.org/jira/browse/JCLOUDS-181
>             Project: jclouds
>          Issue Type: Bug
>          Components: jclouds-blobstore
>    Affects Versions: 1.6.1
>            Reporter: Diwaker Gupta
>
> jclouds added the "Expect: 100-Continue" to the putBlob API for most 
> blobstores sometime back. Handling of 100-continue differs between JDK6 and 
> JDK7 in that unlike JDK6, JDK7 will expect a response from the server and 
> will only time out IF a read timeout has been set on the underlying HTTP 
> connection [1].
> As a result, if applications set Constants.PROPERTY_SO_TIMEOUT and use a 
> blobstore that doesn't properly support the Expect header (i.e., doesn't 
> respond with 100-Continue) on JDK7, the putBlob operation will essentially 
> hang forever.
> Specifically, both HPCS and Google Cloud Storage are impacted by this.
> [1] 
> http://grepcode.com/file/repository.grepcode.com/java/root/jdk/openjdk/7-b147/sun/net/www/protocol/http/HttpURLConnection.java?av=f#1008

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to