Uploaded image for project: 'Maven Wrapper'
  1. Maven Wrapper
  2. MWRAPPER-69

MVNW_REPOURL path not considered

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Duplicate
    • 3.1.1
    • None
    • Maven Wrapper Jar
    • None
    • Microsoft Windows 10

    Description

      As far as I can see, this is a new bug introduced in 3.1.1

      running the plugin with said environment variable set, the plugin correctly writes the repository url into the maven-wrapper.properties.

      using the maven wrapper however, the path part from the url is ignored and just the protocol://host:port part is used.

      Version 3.1.1 (fails)

      SET MVNW_REPOURL=http://myrepository.mine/base/path
      
      [INFO] Apache Maven Wrapper 3.1.1
      [INFO] Detected MVNW_REPOURL environment variable http://myrepository.mine/base/path
      [INFO] Installing Maven distribution C:\Users\developer\.m2\wrapper\dists\apache-maven-3.8.1-bin\726df79b
      [INFO] Downloading http://myrepository.mine/org/apache/maven/apache-maven/3.8.1/apache-maven-3.8.1-bin.zip
      [WARNING] Using an insecure connection to download the Maven distribution. Please consider using HTTPS.
      Exception in thread "main" java.io.FileNotFoundException: http://myrepository.mine/org/apache/maven/apache-maven/3.8.1/apache-maven-3.8.1-bin.zip
              at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1890)
              at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1492)
              at org.apache.maven.wrapper.DefaultDownloader.downloadInternal(DefaultDownloader.java:109)
              at org.apache.maven.wrapper.DefaultDownloader.download(DefaultDownloader.java:97)
              at org.apache.maven.wrapper.Installer.createDist(Installer.java:94)
              at org.apache.maven.wrapper.WrapperExecutor.execute(WrapperExecutor.java:151)
              at org.apache.maven.wrapper.MavenWrapperMain.main(MavenWrapperMain.java:76)
      
      

       

      Version 3.1.0 (working)

      SET MVNW_REPOURL=http://myrepository.mine/base/path 
      
      Apache Maven Wrapper 3.1.0
      Detected MVNW_REPOURL environment variable http://myrepository.mine/base/path
      Installing Maven distribution C:\Users\developer\.m2\wrapper\dists\apache-maven-3.8.1-bin\5rncivls3ihmmbfjma6p3gsnss
      Downloading http://myrepository.mine/base/path/org/apache/maven/apache-maven/3.8.1/apache-maven-3.8.1-bin.zip
      WARNING Using HTTP Basic Authentication over an insecure connection to download the Maven distribution. Please consider using HTTPS.
      .
      .
      .
      .
      .
      .
      .
      .
      .
      .
      .
      .
      .
      .
      .
      .
      .
      .
      .Unzipping C:\Users\developer\.m2\wrapper\dists\apache-maven-3.8.1-bin\5rncivls3ihmmbfjma6p3gsnss\apache-maven-3.8.1-bin.zip to C:\Users\developer\.m2\wrapper\dists\apache-maven-3.8.1-bin\5rncivls3ihmmbfjma6p3gsnss        

       

       

       

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              caroso-de Carsten Rohde
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: