Uploaded image for project: 'Maven'
  1. Maven
  2. MNG-4465

[regression] can't run mvn help:effective-settings when offline

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 3.0-alpha-4
    • 3.0-alpha-6
    • None
    • None
    • Vista, JDK 1.6.0_12,

    Description

      When no internet access is available, certain commands fail with an error.

      >mvn help:effective-settings -X -e
      Apache Maven 3.0-alpha-4 (r835944; 2009-11-13 19:06:31+0100)
      Java version: 1.6.0_12
      Java home: D:\Dev\Java\jdk1.6.0_12\jre
      Default locale: fr_FR, platform encoding: Cp1252
      OS name: "windows vista" version: "6.0" arch: "x86" Family: "windows"
      [INFO] Error stacktraces are turned on.
      [DEBUG] Reading user settings from C:\Users\fbricon\.m2\settings.xml
      [DEBUG] Reading global settings from D:\Dev\maven\apache-maven-3.0-alpha-4\conf\settings.xml
      [DEBUG] Using local repository at D:\Dev\maven\repository
      [INFO] Scanning for projects...
      [DEBUG] Extension realms for project org.apache.maven:standalone-pom:pom:1: (none)
      Downloading: http://repo1.maven.org/maven2/org/apache/maven/plugins/maven-metadata.xml
      [WARNING] Failed to retrieve org/apache/maven/plugins/maven-metadata.xml: Error transferring artifact.
      org.apache.maven.repository.ArtifactTransferFailedException: Error transferring artifact.
      	at org.apache.maven.repository.legacy.LegacyRepositorySystem.retrieve(LegacyRepositorySystem.java:597)
      	at org.apache.maven.plugin.prefix.internal.DefaultPluginPrefixResolver.resolveFromRepository(DefaultPluginPrefixResolver.java:175)
      	at org.apache.maven.plugin.prefix.internal.DefaultPluginPrefixResolver.resolve(DefaultPluginPrefixResolver.java:75)
      	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.findPluginForPrefix(DefaultLifecycleExecutor.java:1763)
      	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.getMojoDescriptor(DefaultLifecycleExecutor.java:1507)
      	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.calculateTaskSegments(DefaultLifecycleExecutor.java:828)
      	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.calculateProjectBuilds(DefaultLifecycleExecutor.java:718)
      	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:236)
      	at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:239)
      	at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:102)
      	at org.apache.maven.cli.MavenCli.execute(MavenCli.java:421)
      	at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:156)
      	at org.apache.maven.cli.MavenCli.main(MavenCli.java:121)
      	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      	at java.lang.reflect.Method.invoke(Method.java:597)
      	at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:290)
      	at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:230)
      	at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:409)
      	at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:352)
      Caused by: org.apache.maven.wagon.TransferFailedException: Error transferring file: repo1.maven.org
      	at org.apache.maven.wagon.providers.http.LightweightHttpWagon.fillInputData(LightweightHttpWagon.java:143)
      	at org.apache.maven.wagon.StreamWagon.getInputStream(StreamWagon.java:116)
      	at org.apache.maven.wagon.StreamWagon.getIfNewer(StreamWagon.java:88)
      	at org.apache.maven.wagon.StreamWagon.get(StreamWagon.java:61)
      	at org.apache.maven.repository.legacy.DefaultWagonManager.getRemoteFile(DefaultWagonManager.java:310)
      	at org.apache.maven.repository.legacy.LegacyRepositorySystem.retrieve(LegacyRepositorySystem.java:591)
      	... 20 more
      Caused by: java.net.UnknownHostException: repo1.maven.org
      	at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:177)
      	at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:366)
      	at java.net.Socket.connect(Socket.java:519)
      	at java.net.Socket.connect(Socket.java:469)
      	at sun.net.NetworkClient.doConnect(NetworkClient.java:163)
      	at sun.net.www.http.HttpClient.openServer(HttpClient.java:394)
      	at sun.net.www.http.HttpClient.openServer(HttpClient.java:529)
      	at sun.net.www.http.HttpClient.<init>(HttpClient.java:233)
      	at sun.net.www.http.HttpClient.New(HttpClient.java:306)
      	at sun.net.www.http.HttpClient.New(HttpClient.java:323)
      	at sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(HttpURLConnection.java:837)
      	at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:778)
      	at sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection.java:703)
      	at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1026)
      	at java.net.HttpURLConnection.getResponseCode(HttpURLConnection.java:373)
      	at org.apache.maven.wagon.providers.http.LightweightHttpWagon.fillInputData(LightweightHttpWagon.java:115)
      	... 25 more
      Downloading: http://repo1.maven.org/maven2/org/codehaus/mojo/maven-metadata.xml
      [WARNING] Failed to retrieve org/codehaus/mojo/maven-metadata.xml: Error transferring artifact.
      org.apache.maven.repository.ArtifactTransferFailedException: Error transferring artifact.
      	at org.apache.maven.repository.legacy.LegacyRepositorySystem.retrieve(LegacyRepositorySystem.java:597)
      	at org.apache.maven.plugin.prefix.internal.DefaultPluginPrefixResolver.resolveFromRepository(DefaultPluginPrefixResolver.java:175)
      	at org.apache.maven.plugin.prefix.internal.DefaultPluginPrefixResolver.resolve(DefaultPluginPrefixResolver.java:75)
      	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.findPluginForPrefix(DefaultLifecycleExecutor.java:1763)
      	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.getMojoDescriptor(DefaultLifecycleExecutor.java:1507)
      	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.calculateTaskSegments(DefaultLifecycleExecutor.java:828)
      	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.calculateProjectBuilds(DefaultLifecycleExecutor.java:718)
      	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:236)
      	at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:239)
      	at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:102)
      	at org.apache.maven.cli.MavenCli.execute(MavenCli.java:421)
      	at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:156)
      	at org.apache.maven.cli.MavenCli.main(MavenCli.java:121)
      	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      	at java.lang.reflect.Method.invoke(Method.java:597)
      	at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:290)
      	at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:230)
      	at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:409)
      	at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:352)
      Caused by: org.apache.maven.wagon.TransferFailedException: Error transferring file: repo1.maven.org
      	at org.apache.maven.wagon.providers.http.LightweightHttpWagon.fillInputData(LightweightHttpWagon.java:143)
      	at org.apache.maven.wagon.StreamWagon.getInputStream(StreamWagon.java:116)
      	at org.apache.maven.wagon.StreamWagon.getIfNewer(StreamWagon.java:88)
      	at org.apache.maven.wagon.StreamWagon.get(StreamWagon.java:61)
      	at org.apache.maven.repository.legacy.DefaultWagonManager.getRemoteFile(DefaultWagonManager.java:310)
      	at org.apache.maven.repository.legacy.LegacyRepositorySystem.retrieve(LegacyRepositorySystem.java:591)
      	... 20 more
      Caused by: java.net.UnknownHostException: repo1.maven.org
      	at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:177)
      	at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:366)
      	at java.net.Socket.connect(Socket.java:519)
      	at java.net.Socket.connect(Socket.java:469)
      	at sun.net.NetworkClient.doConnect(NetworkClient.java:163)
      	at sun.net.www.http.HttpClient.openServer(HttpClient.java:394)
      	at sun.net.www.http.HttpClient.openServer(HttpClient.java:529)
      	at sun.net.www.http.HttpClient.<init>(HttpClient.java:233)
      	at sun.net.www.http.HttpClient.New(HttpClient.java:306)
      	at sun.net.www.http.HttpClient.New(HttpClient.java:323)
      	at sun.net.www.protocol.http.HttpURLConnection.getNewHttpClient(HttpURLConnection.java:837)
      	at sun.net.www.protocol.http.HttpURLConnection.plainConnect(HttpURLConnection.java:778)
      	at sun.net.www.protocol.http.HttpURLConnection.connect(HttpURLConnection.java:703)
      	at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1026)
      	at java.net.HttpURLConnection.getResponseCode(HttpURLConnection.java:373)
      	at org.apache.maven.wagon.providers.http.LightweightHttpWagon.fillInputData(LightweightHttpWagon.java:115)
      	... 25 more
      [INFO] ------------------------------------------------------------------------
      [INFO] BUILD FAILURE
      [INFO] ------------------------------------------------------------------------
      [INFO] Total time: 2.704s
      [INFO] Finished at: Mon Nov 23 19:32:26 CET 2009
      [INFO] Final Memory: 3M/11M
      [INFO] ------------------------------------------------------------------------
      [ERROR] No plugin found for prefix 'help' in the current project and in the plugin groups [org.apache.maven.plugins, org.codehaus.mojo] available from the repositories [local (D:\Dev\maven\repository), central (http://repo1.maven.org/maven2)] -> [Help 1]
      org.apache.maven.plugin.prefix.NoPluginFoundForPrefixException: No plugin found for prefix 'help' in the current project and in the plugin groups [org.apache.maven.plugins, org.codehaus.mojo] available from the repositories [local (D:\Dev\maven\repository), central (http://repo1.maven.org/maven2)]
      	at org.apache.maven.plugin.prefix.internal.DefaultPluginPrefixResolver.resolve(DefaultPluginPrefixResolver.java:79)
      	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.findPluginForPrefix(DefaultLifecycleExecutor.java:1763)
      	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.getMojoDescriptor(DefaultLifecycleExecutor.java:1507)
      	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.calculateTaskSegments(DefaultLifecycleExecutor.java:828)
      	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.calculateProjectBuilds(DefaultLifecycleExecutor.java:718)
      	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:236)
      	at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:239)
      	at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:102)
      	at org.apache.maven.cli.MavenCli.execute(MavenCli.java:421)
      	at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:156)
      	at org.apache.maven.cli.MavenCli.main(MavenCli.java:121)
      	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      	at java.lang.reflect.Method.invoke(Method.java:597)
      	at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:290)
      	at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:230)
      	at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:409)
      	at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:352)
      [ERROR] 
      [ERROR] 
      [ERROR] For more information about the errors and possible solutions, please read the following articles:
      [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/NoPluginFoundForPrefixException
      
      

      Using the offline switch (-o) works, fortunately, but this behavior is a regression from 2.2.1 and previous versions.

      regards,

      Fred Bricon

      Attachments

        Issue Links

          Activity

            People

              bentmann Benjamin Bentmann
              fbricon Fred Bricon
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: