You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Mehul Sanghvi <me...@gmail.com> on 2017/07/26 13:21:20 UTC

Maven return code 502, ReasonPhrase:notresolvable

Maven version:  3.3.3
Nexus version:   OSS 2.14.o-1

Starting this past Monday, I have been seeing the following:


build 25-Jul-2017 20:27:16 [ERROR] Failed to execute goal
org.apache.maven.plugins:maven-antrun-plugin:1.3:run (default) on project
xml2jsonMigration: Execution default of goal
org.apache.maven.plugins:maven-antrun-plugin:1.3:run failed: Plugin
org.apache.maven.plugins:maven-antrun-plugin:1.3 or one of its dependencies
could not be resolved: The following artifacts could not be resolved:
org.apache.maven:maven-plugin-api:jar:2.0.4,
org.apache.maven:maven-project:jar:2.0.4,
org.apache.maven:maven-settings:jar:2.0.4,
org.apache.maven:maven-profile:jar:2.0.4,
org.apache.maven:maven-model:jar:2.0.4,
org.apache.maven:maven-artifact-manager:jar:2.0.4,
org.apache.maven:maven-repository-metadata:jar:2.0.4,
org.apache.maven:maven-artifact:jar:2.0.4,
org.codehaus.plexus:plexus-utils:jar:1.5.6: Could not transfer artifact
org.apache.maven:maven-plugin-api:jar:2.0.4 from/to releases
(http://nexus.myorg.com:8081/nexus/content/groups/releases/): Failed to
transfer file:
http://nexus.myorg.com:8081/nexus/content/groups/releases/org/apache/maven/maven-plugin-api/2.0.4/maven-plugin-api-2.0.4.jar.
Return code is: 502 ,
ReasonPhrase:notresolvable.


At first it was for an artefact that was located in an internal corporate
Artifactory repository, which I was able to get past by modifying the proxy
settings in the settings.xml file.   It used to be:

            <nonProxyHosts>*.myorg.com</nonProxyHosts>

and I changed it to

            <nonProxyHosts>*.myorg.com|*.mycorp.com</nonProxyHosts>



The error above that I am getting though, is for something that was
working.  And the artefacts are accessible via the web browser.  From a
network standpoint, the Nexus server is one hop away (based on traceroute
information).

This used to work.   There have been no network changes,  not VM changes,
 no updates to Maven.   We did change the version number of our product by
removing the -SNAPSHOT, but that should not cause this error that we are
seeing.

I have tried using the -U command line option, as well as just pointing
maven.repo.local to a new location and avoiding any cacheing issues.


Any pointers/suggestions/thoughts ?

-- 
Mehul N. Sanghvi
email: mehul.sanghvi@gmail.com

Re: Maven return code 502, ReasonPhrase:notresolvable

Posted by Mehul Sanghvi <me...@gmail.com>.
Hi Karl,

    I will see what happens with the version change from 1.3 of
maven-antrun-plugin, I will try to take a look into that and see if I can
make those changes.  Looking in the POM file there is no version specified
for it explicitly.  I'll have to see where that is coming from.

     "Return code is: 502 , ReasonPhrase:notresolvable."  is the error
Maven provides and looking at:
http://cwiki.apache.org/confluence/display/MAVEN/PluginResolutionException
 which is the link provided in the exception thrown by Maven, I have tried
the suggestions provided there to no avail.

    We do not have anything else between Maven and Nexus.  There is no
Apache HTTP server in between, it is a direct connection to Nexus, so its
Nexus OSS plain.  The artefacts I listed in the original email below, are
the only artefacts that are affected.  All other artefacts are downloaded
just fine.  No Nexus changes have been made, I have already checked that.


---- BEGIN settings.xml ------
<?xml version="1.0" encoding="UTF-8"?>
<!-- Copy settings.xml.template into your .m2 repository as
"settings.xml"-->
<settings>
    <proxies>
        <proxy>
            <protocol>http</protocol>
            <host>corp-proxy-server.mycorp.com</host>
            <port>80</port>
            <nonProxyHosts>*.oldcorp.com|*.mycorp*.com</nonProxyHosts>
        </proxy>
    </proxies>

    <mirrors>
        <!-- Use our internal Nexus repo instead of Maven Central -->
        <mirror>
            <id>releases</id>
            <name>Internal Nexus Releases</name>
            <url>
http://nexusoss.mycorp.com:8081/nexus/content/groups/releases</url>
            <mirrorOf>central</mirrorOf>
        </mirror>
    </mirrors>

    <profiles>
        <profile>
            <id>configure-snapshot-repository</id>
            <activation>
                <activeByDefault>true</activeByDefault>
            </activation>
            <repositories>
                <repository>
                    <id>snapshots</id>
                    <name>Internal Nexus Snapshots</name>
                    <url>
http://nexusoss.mycorp.com:8081/nexus/content/groups/snapshots</url>
                    <releases>
                        <enabled>false</enabled>
                    </releases>
                    <snapshots>
                        <enabled>true</enabled>
                        <updatePolicy>always</updatePolicy>
                    </snapshots>
                </repository>
<repository>
                    <id>releases</id>
                    <name>Internal Nexus Releases</name>
                    <url>
http://nexusoss.mycorp.com:8081/nexus/content/groups/releases/</url>
                    <releases>
                        <enabled>true</enabled>
                    </releases>
                    <snapshots>
                        <enabled>false</enabled>
                        <updatePolicy>always</updatePolicy>
                    </snapshots>
                </repository>
            </repositories>
            <pluginRepositories>
                <pluginRepository>
                    <id>snapshots</id>
                    <name>Internal Nexus Snapshots</name>
                    <url>
http://nexusoss.mycorp.com:8081/nexus/content/groups/snapshots</url>
                    <releases>
                        <enabled>false</enabled>
                    </releases>
                    <snapshots>
                        <enabled>true</enabled>
                        <updatePolicy>always</updatePolicy>
                    </snapshots>
                </pluginRepository>
<pluginRepository>
                    <id>releases</id>
                    <name>Internal Nexus Releases</name>
                    <url>
http://nexusoss.mycorp.com:8081/nexus/content/groups/releases/</url>
                    <releases>
                        <enabled>true</enabled>
                    </releases>
                    <snapshots>
                        <enabled>false</enabled>
                        <updatePolicy>always</updatePolicy>
                    </snapshots>
                </pluginRepository>
            </pluginRepositories>
        </profile>
        <profile>
            <id>override-properties</id>
            <activation>
                <activeByDefault>true</activeByDefault>
            </activation>
            <properties>
                <!-- You can override property values for your build
environment here
                     without having to make changes to POMs in version
control. Some
                     examples of properties you might want to do this with
follow. -->

                <!-- Location of the standalone flash player that should be
used to run unit tests -->
                <!-- <flashPlayer.command>C:\Program Files
(x86)\Adobe\Adobe Flash Builder 4
Plug-in\player\win\10.1\FlashPlayerDebugger.exe</flashPlayer.command> -->

                <!-- Location to install bundles to when the sling:install
goal is invoked -->
                <!-- <sling.url>
http://some-remote-host:8006/ifcr/system/console</sling.url> -->

                <!-- Smoke/Integration test overrides -->
                <!-- <host.name>some-remote-host</host.name> -->
                <!--
<browser.binary>/opt/firefox-3.6/firefox</browser.binary> -->
            </properties>
        </profile>

        <profile>
            <id>use-maven-central</id>
            <repositories>
                <repository>
                    <id>remote-central</id>
                    <url>http://repo1.maven.org/maven2</url>
                </repository>
            </repositories>
            <pluginRepositories>
                <pluginRepository>
                    <id>remote-central</id>
                    <url>http://repo2.maven.org/maven2</url>
                </pluginRepository>
            </pluginRepositories>
        </profile>
    </profiles>

    <servers>
        <server>
            <id>suborg-snapshots</id>
            <filePermissions>664</filePermissions>
            <directoryPermissions>775</directoryPermissions>
            <!-- see
http://maven.apache.org/guides/mini/guide-encryption.html -->
            <username>nightly</username>
            <password>some-password</password>
        </server>
        <server>
            <id>suborg-releases</id>
            <filePermissions>664</filePermissions>
            <directoryPermissions>775</directoryPermissions>
            <!-- see
http://maven.apache.org/guides/mini/guide-encryption.html -->
            <username>nightly</username>
            <password>some-password</password>
        </server>
    </servers>
</settings>

----- END settings.xml -----


On Sun, Aug 13, 2017 at 12:56 PM, Karl Heinz Marbaise <kh...@gmx.de>
wrote:

> Hi,
>
> first recommendation I can give is upgrade the plugin versions cause 1.3
> from 2008 ...is really old...
>
> furthermore error code 502 is "Bad Gateway"...do you have an Apache http
> server between you and the Nexus ? Or do you use Nexus plain...? Sounds
> like an issue on network level...Or bad configuration of Nexus etc..
>
> How does your settings.xml look like?
>
> Kind regards
> Karl Heinz Marbaise
>
> On 13/08/17 18:29, Mehul Sanghvi wrote:
>
>> I upgraded my Nexus OSS server to version 2.14.5-02, and I still see the
>> same issue.  All new builds that I have
>> get affected by this, unless I manually copy the artefacts from an
>> existing
>> local maven repository.
>>
>> I have rebuilt the metadata, re-built the indexes, etc. as well.  Still
>> the
>> same result.
>>
>> Anyone have any thoughts/suggestions/pointers ?
>>
>> cheers,
>>
>>       mehul
>>
>>
>> On Wed, Jul 26, 2017 at 9:21 AM, Mehul Sanghvi <me...@gmail.com>
>> wrote:
>>
>> Maven version:  3.3.3
>>> Nexus version:   OSS 2.14.o-1
>>>
>>> Starting this past Monday, I have been seeing the following:
>>>
>>>
>>> build 25-Jul-2017 20:27:16 [ERROR] Failed to execute goal
>>> org.apache.maven.plugins:maven-antrun-plugin:1.3:run (default) on
>>> project
>>> xml2jsonMigration: Execution default of goal
>>> org.apache.maven.plugins:maven-antrun-plugin:1.3:run failed: Plugin
>>> org.apache.maven.plugins:maven-antrun-plugin:1.3 or one of its
>>> dependencies
>>> could not be resolved: The following artifacts could not be resolved:
>>> org.apache.maven:maven-plugin-api:jar:2.0.4,
>>> org.apache.maven:maven-project:jar:2.0.4,
>>> org.apache.maven:maven-settings:jar:2.0.4,
>>> org.apache.maven:maven-profile:jar:2.0.4,
>>> org.apache.maven:maven-model:jar:2.0.4,
>>> org.apache.maven:maven-artifact-manager:jar:2.0.4,
>>> org.apache.maven:maven-repository-metadata:jar:2.0.4,
>>> org.apache.maven:maven-artifact:jar:2.0.4,
>>> org.codehaus.plexus:plexus-utils:jar:1.5.6: Could not transfer artifact
>>> org.apache.maven:maven-plugin-api:jar:2.0.4 from/to releases
>>> (http://nexus.myorg.com:8081/nexus/content/groups/releases/): Failed to
>>> transfer file:
>>> http://nexus.myorg.com:8081/nexus/content/groups/releases/
>>> org/apache/maven/maven-plugin-api/2.0.4/maven-plugin-api-2.0.4.jar.
>>> Return code is: 502 ,
>>> ReasonPhrase:notresolvable.
>>>
>>>
>>> At first it was for an artefact that was located in an internal corporate
>>> Artifactory repository, which I was able to get past by modifying the
>>> proxy
>>> settings in the settings.xml file.   It used to be:
>>>
>>>              <nonProxyHosts>*.myorg.com</nonProxyHosts>
>>>
>>> and I changed it to
>>>
>>>              <nonProxyHosts>*.myorg.com|*.mycorp.com</nonProxyHosts>
>>>
>>>
>>>
>>> The error above that I am getting though, is for something that was
>>> working.  And the artefacts are accessible via the web browser.  From a
>>> network standpoint, the Nexus server is one hop away (based on traceroute
>>> information).
>>>
>>> This used to work.   There have been no network changes,  not VM changes,
>>>   no updates to Maven.   We did change the version number of our product
>>> by
>>> removing the -SNAPSHOT, but that should not cause this error that we are
>>> seeing.
>>>
>>> I have tried using the -U command line option, as well as just pointing
>>> maven.repo.local to a new location and avoiding any cacheing issues.
>>>
>>>
>>> Any pointers/suggestions/thoughts ?
>>>
>>>


-- 
Mehul N. Sanghvi
email: mehul.sanghvi@gmail.com

Re: Maven return code 502, ReasonPhrase:notresolvable

Posted by Karl Heinz Marbaise <kh...@gmx.de>.
Hi,

first recommendation I can give is upgrade the plugin versions cause 1.3 
from 2008 ...is really old...

furthermore error code 502 is "Bad Gateway"...do you have an Apache http 
server between you and the Nexus ? Or do you use Nexus plain...? Sounds 
like an issue on network level...Or bad configuration of Nexus etc..

How does your settings.xml look like?

Kind regards
Karl Heinz Marbaise
On 13/08/17 18:29, Mehul Sanghvi wrote:
> I upgraded my Nexus OSS server to version 2.14.5-02, and I still see the
> same issue.  All new builds that I have
> get affected by this, unless I manually copy the artefacts from an existing
> local maven repository.
> 
> I have rebuilt the metadata, re-built the indexes, etc. as well.  Still the
> same result.
> 
> Anyone have any thoughts/suggestions/pointers ?
> 
> cheers,
> 
>       mehul
> 
> 
> On Wed, Jul 26, 2017 at 9:21 AM, Mehul Sanghvi <me...@gmail.com>
> wrote:
> 
>> Maven version:  3.3.3
>> Nexus version:   OSS 2.14.o-1
>>
>> Starting this past Monday, I have been seeing the following:
>>
>>
>> build 25-Jul-2017 20:27:16 [ERROR] Failed to execute goal
>> org.apache.maven.plugins:maven-antrun-plugin:1.3:run (default) on project
>> xml2jsonMigration: Execution default of goal
>> org.apache.maven.plugins:maven-antrun-plugin:1.3:run failed: Plugin
>> org.apache.maven.plugins:maven-antrun-plugin:1.3 or one of its
>> dependencies
>> could not be resolved: The following artifacts could not be resolved:
>> org.apache.maven:maven-plugin-api:jar:2.0.4,
>> org.apache.maven:maven-project:jar:2.0.4,
>> org.apache.maven:maven-settings:jar:2.0.4,
>> org.apache.maven:maven-profile:jar:2.0.4,
>> org.apache.maven:maven-model:jar:2.0.4,
>> org.apache.maven:maven-artifact-manager:jar:2.0.4,
>> org.apache.maven:maven-repository-metadata:jar:2.0.4,
>> org.apache.maven:maven-artifact:jar:2.0.4,
>> org.codehaus.plexus:plexus-utils:jar:1.5.6: Could not transfer artifact
>> org.apache.maven:maven-plugin-api:jar:2.0.4 from/to releases
>> (http://nexus.myorg.com:8081/nexus/content/groups/releases/): Failed to
>> transfer file:
>> http://nexus.myorg.com:8081/nexus/content/groups/releases/
>> org/apache/maven/maven-plugin-api/2.0.4/maven-plugin-api-2.0.4.jar.
>> Return code is: 502 ,
>> ReasonPhrase:notresolvable.
>>
>>
>> At first it was for an artefact that was located in an internal corporate
>> Artifactory repository, which I was able to get past by modifying the proxy
>> settings in the settings.xml file.   It used to be:
>>
>>              <nonProxyHosts>*.myorg.com</nonProxyHosts>
>>
>> and I changed it to
>>
>>              <nonProxyHosts>*.myorg.com|*.mycorp.com</nonProxyHosts>
>>
>>
>>
>> The error above that I am getting though, is for something that was
>> working.  And the artefacts are accessible via the web browser.  From a
>> network standpoint, the Nexus server is one hop away (based on traceroute
>> information).
>>
>> This used to work.   There have been no network changes,  not VM changes,
>>   no updates to Maven.   We did change the version number of our product by
>> removing the -SNAPSHOT, but that should not cause this error that we are
>> seeing.
>>
>> I have tried using the -U command line option, as well as just pointing
>> maven.repo.local to a new location and avoiding any cacheing issues.
>>
>>
>> Any pointers/suggestions/thoughts ?
>>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Maven return code 502, ReasonPhrase:notresolvable

Posted by Mehul Sanghvi <me...@gmail.com>.
I upgraded my Nexus OSS server to version 2.14.5-02, and I still see the
same issue.  All new builds that I have
get affected by this, unless I manually copy the artefacts from an existing
local maven repository.

I have rebuilt the metadata, re-built the indexes, etc. as well.  Still the
same result.

Anyone have any thoughts/suggestions/pointers ?

cheers,

     mehul


On Wed, Jul 26, 2017 at 9:21 AM, Mehul Sanghvi <me...@gmail.com>
wrote:

> Maven version:  3.3.3
> Nexus version:   OSS 2.14.o-1
>
> Starting this past Monday, I have been seeing the following:
>
>
> build 25-Jul-2017 20:27:16 [ERROR] Failed to execute goal
> org.apache.maven.plugins:maven-antrun-plugin:1.3:run (default) on project
> xml2jsonMigration: Execution default of goal
> org.apache.maven.plugins:maven-antrun-plugin:1.3:run failed: Plugin
> org.apache.maven.plugins:maven-antrun-plugin:1.3 or one of its
> dependencies
> could not be resolved: The following artifacts could not be resolved:
> org.apache.maven:maven-plugin-api:jar:2.0.4,
> org.apache.maven:maven-project:jar:2.0.4,
> org.apache.maven:maven-settings:jar:2.0.4,
> org.apache.maven:maven-profile:jar:2.0.4,
> org.apache.maven:maven-model:jar:2.0.4,
> org.apache.maven:maven-artifact-manager:jar:2.0.4,
> org.apache.maven:maven-repository-metadata:jar:2.0.4,
> org.apache.maven:maven-artifact:jar:2.0.4,
> org.codehaus.plexus:plexus-utils:jar:1.5.6: Could not transfer artifact
> org.apache.maven:maven-plugin-api:jar:2.0.4 from/to releases
> (http://nexus.myorg.com:8081/nexus/content/groups/releases/): Failed to
> transfer file:
> http://nexus.myorg.com:8081/nexus/content/groups/releases/
> org/apache/maven/maven-plugin-api/2.0.4/maven-plugin-api-2.0.4.jar.
> Return code is: 502 ,
> ReasonPhrase:notresolvable.
>
>
> At first it was for an artefact that was located in an internal corporate
> Artifactory repository, which I was able to get past by modifying the proxy
> settings in the settings.xml file.   It used to be:
>
>             <nonProxyHosts>*.myorg.com</nonProxyHosts>
>
> and I changed it to
>
>             <nonProxyHosts>*.myorg.com|*.mycorp.com</nonProxyHosts>
>
>
>
> The error above that I am getting though, is for something that was
> working.  And the artefacts are accessible via the web browser.  From a
> network standpoint, the Nexus server is one hop away (based on traceroute
> information).
>
> This used to work.   There have been no network changes,  not VM changes,
>  no updates to Maven.   We did change the version number of our product by
> removing the -SNAPSHOT, but that should not cause this error that we are
> seeing.
>
> I have tried using the -U command line option, as well as just pointing
> maven.repo.local to a new location and avoiding any cacheing issues.
>
>
> Any pointers/suggestions/thoughts ?
>
> --
> Mehul N. Sanghvi
> email: mehul.sanghvi@gmail.com
>



-- 
Mehul N. Sanghvi
email: mehul.sanghvi@gmail.com