Uploaded image for project: 'Maven Wagon'
  1. Maven Wagon
  2. WAGON-469

wagon-http does not enable Expect-Continue by default

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.10
    • Fix Version/s: 2.12
    • Component/s: wagon-http
    • Labels:
      None

      Description

      According to http://maven.apache.org/guides/mini/guide-http-settings.html#The_Basics PUT requests made with the HTTP wagon will enable Expect-Continue support by default.

      However testing shows that when no <httpConfiguration> is provided in settings.xml Expect-Continue support is not enabled by wagon-http for PUT requests.

      Similarly, when an empty <httpConfiguration> section is provided in settings.xml, Expect-Continue support is not enabled by wagon-http for PUT requests.

      Only when a <httpConfiguration> section like:

      <put>
        <params>
          <property>
            <name>http.protocol.expect-continue</name>
            <value>%b,true</value>
          </property>
        </params>
      </put>
      

      is provided in settings.xml is Expect-Continue support enabled.

        Issue Links

          Activity

          Hide
          githubbot ASF GitHub Bot added a comment -

          GitHub user mcculls opened a pull request:

          https://github.com/apache/maven-wagon/pull/31

          WAGON-469 wagon-http does not enable Expect-Continue by default

          There appear to be two issues:

          • Expect-Continue is not enabled for PUT when no configuration is provided
          • The default Expect-Continue configuration parameter uses the wrong key

          You can merge this pull request into a Git repository by running:

          $ git pull https://github.com/mcculls/maven-wagon WAGON-469-enable-expect-continue-by-default

          Alternatively you can review and apply these changes as the patch at:

          https://github.com/apache/maven-wagon/pull/31.patch

          To close this pull request, make a commit to your master/trunk branch
          with (at least) the following in the commit message:

          This closes #31


          commit 5913a71aaf556a8583decf5b1e5c39e946a153a8
          Author: Stuart McCulloch <mcculls@gmail.com>
          Date: 2016-12-09T23:04:25Z

          WAGON-469 enable Expect-Continue for PUTs when no configuration is provided

          commit 6aab1bd0685c00cd72253b9ba7e6e0d6da7e3172
          Author: Stuart McCulloch <mcculls@gmail.com>
          Date: 2016-12-09T23:05:36Z

          WAGON-469 use correct key for default Expect-Continue configuration parameter

          (HTTP.EXPECT_CONTINUE constant is the expectation name, not the parameter key)


          Show
          githubbot ASF GitHub Bot added a comment - GitHub user mcculls opened a pull request: https://github.com/apache/maven-wagon/pull/31 WAGON-469 wagon-http does not enable Expect-Continue by default There appear to be two issues: Expect-Continue is not enabled for PUT when no configuration is provided The default Expect-Continue configuration parameter uses the wrong key You can merge this pull request into a Git repository by running: $ git pull https://github.com/mcculls/maven-wagon WAGON-469 -enable-expect-continue-by-default Alternatively you can review and apply these changes as the patch at: https://github.com/apache/maven-wagon/pull/31.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #31 commit 5913a71aaf556a8583decf5b1e5c39e946a153a8 Author: Stuart McCulloch <mcculls@gmail.com> Date: 2016-12-09T23:04:25Z WAGON-469 enable Expect-Continue for PUTs when no configuration is provided commit 6aab1bd0685c00cd72253b9ba7e6e0d6da7e3172 Author: Stuart McCulloch <mcculls@gmail.com> Date: 2016-12-09T23:05:36Z WAGON-469 use correct key for default Expect-Continue configuration parameter (HTTP.EXPECT_CONTINUE constant is the expectation name, not the parameter key)
          Hide
          mcculls Stuart McCulloch added a comment -
          Show
          mcculls Stuart McCulloch added a comment - Suggested patch: https://github.com/apache/maven-wagon/pull/31
          Hide
          githubbot ASF GitHub Bot added a comment -

          Github user michael-o commented on the issue:

          https://github.com/apache/maven-wagon/pull/31

          Looks very good. Please squash and I will merge it.

          Show
          githubbot ASF GitHub Bot added a comment - Github user michael-o commented on the issue: https://github.com/apache/maven-wagon/pull/31 Looks very good. Please squash and I will merge it.
          Hide
          githubbot ASF GitHub Bot added a comment -

          Github user mcculls commented on the issue:

          https://github.com/apache/maven-wagon/pull/31

          OK, squashed

          Show
          githubbot ASF GitHub Bot added a comment - Github user mcculls commented on the issue: https://github.com/apache/maven-wagon/pull/31 OK, squashed
          Hide
          githubbot ASF GitHub Bot added a comment -

          Github user asfgit closed the pull request at:

          https://github.com/apache/maven-wagon/pull/31

          Show
          githubbot ASF GitHub Bot added a comment - Github user asfgit closed the pull request at: https://github.com/apache/maven-wagon/pull/31
          Hide
          michael-o Michael Osipov added a comment -
          Show
          michael-o Michael Osipov added a comment - Fixed with 5d600267c4e8f1a27b32bed91a557e696bd66fc3 .
          Hide
          hudson Hudson added a comment -

          SUCCESS: Integrated in Jenkins build maven-wagon #1318 (See https://builds.apache.org/job/maven-wagon/1318/)
          WAGON-469 wagon-http does not enable Expect-Continue by default (michaelo: rev 5d600267c4e8f1a27b32bed91a557e696bd66fc3)

          • (edit) wagon-providers/wagon-http/src/main/java/org/apache/maven/wagon/providers/http/HttpConfiguration.java
          • (edit) wagon-providers/wagon-http/src/main/java/org/apache/maven/wagon/providers/http/AbstractHttpClientWagon.java
          Show
          hudson Hudson added a comment - SUCCESS: Integrated in Jenkins build maven-wagon #1318 (See https://builds.apache.org/job/maven-wagon/1318/ ) WAGON-469 wagon-http does not enable Expect-Continue by default (michaelo: rev 5d600267c4e8f1a27b32bed91a557e696bd66fc3) (edit) wagon-providers/wagon-http/src/main/java/org/apache/maven/wagon/providers/http/HttpConfiguration.java (edit) wagon-providers/wagon-http/src/main/java/org/apache/maven/wagon/providers/http/AbstractHttpClientWagon.java

            People

            • Assignee:
              michael-o Michael Osipov
              Reporter:
              mcculls Stuart McCulloch
            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development