aspose file tools*
The moose likes Ant, Maven and Other Build Tools and the fly likes ERROR] Failed to execute goal org.apache.maven.plugins:maven-resources-plugin:2.4.1:resources Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Engineering » Ant, Maven and Other Build Tools
Bookmark "ERROR] Failed to execute goal org.apache.maven.plugins:maven-resources-plugin:2.4.1:resources " Watch "ERROR] Failed to execute goal org.apache.maven.plugins:maven-resources-plugin:2.4.1:resources " New topic
Author

ERROR] Failed to execute goal org.apache.maven.plugins:maven-resources-plugin:2.4.1:resources

Kashif Mughal
Ranch Hand

Joined: Jun 19, 2008
Posts: 44
Hi Everyone,

I have installed the m2eclipse (0.10) for eclipse-j2ee-galileo-SR1-win32bit. After the installation, I had the problem;

1- Plugin "org.apache.maven.plugins:maven-resources-plugin:2.4.1" is missing, I downloaded the JAR for that plugin and copied in to the repository.
2- After copying the plugin now, I am getting the following problem.


===========================================


[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Unnamed - TestWeb:TestWeb:war:0.0.1-SNAPSHOT 0.0.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] --- maven-resources-plugin:2.4.1:resources (default-resources) @ TestWeb ---
2010-06-09 23:57:10.408:INFO::Logging to StdErrLog:EBUG=false via org.eclipse.jetty.util.log.StdErrLog
2010-06-09 23:57:10.658:WARN::FAILED org.eclipse.jetty.client.SelectConnector$Manager@4d76b4: java.io.IOException: Unable to establish loopback connection
2010-06-09 23:57:10.658:WARN::FAILED org.eclipse.jetty.client.SelectConnector@1ac5f13: java.io.IOException: Unable to establish loopback connection
2010-06-09 23:57:10.658:WARN::FAILED org.apache.maven.wagon.providers.http.FixedHttpClient@195dd5b: java.io.IOException: Unable to establish loopback connection
[WARNING] Missing POM for org.apache.maven.plugins:maven-resources-plugin:maven-plugin:2.4.1
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1.032s
[INFO] Finished at: Wed Jun 09 23:57:10 BST 2010
[INFO] Final Memory: 1M/3M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-resources-plugin:2.4.1:resources (default-resources) on project TestWeb: Execution default-resources of goal org.apache.maven.plugins:maven-resources-plugin:2.4.1:resources failed: Unable to load the mojo 'resources' in the plugin 'org.apache.maven.plugins:maven-resources-plugin:2.4.1'. A required class is missing: org/apache/maven/shared/filtering/MavenFilteringException
-----------------------------------------------------
realm = plugin>org.apache.maven.plugins:maven-resources-plugin:2.4.1
strategy = org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy
urls[0] = file:/C:/Documents%20and%20Settings/Kashif%20Mughal/.m2/repository/org/apache/maven/plugins/maven-resources-plugin/2.4.1/maven-resources-plugin-2.4.1.jar
urls[1] = file:/C:/Documents%20and%20Settings/Kashif%20Mughal/.m2/repository/org/codehaus/plexus/plexus-utils/1.1/plexus-utils-1.1.jar
Number of foreign imports: 4
import: Entry[import org.codehaus.plexus.util.xml.pull.XmlSerializer from realm ClassRealm[plexus.core, parent: null]]
import: Entry[import org.codehaus.plexus.util.xml.pull.XmlPullParserException from realm ClassRealm[plexus.core, parent: null]]
import: Entry[import org.codehaus.plexus.util.xml.pull.XmlPullParser from realm ClassRealm[plexus.core, parent: null]]
import: Entry[import org.codehaus.plexus.util.xml.Xpp3Dom from realm ClassRealm[plexus.core, parent: null]]
Number of parent imports: 20
import: Entry[import org.codehaus.plexus.personality from realm null]
import: Entry[import org.codehaus.plexus.logging from realm null]
import: Entry[import org.codehaus.plexus.lifecycle from realm null]
import: Entry[import org.codehaus.plexus.context from realm null]
import: Entry[import org.codehaus.plexus.container from realm null]
import: Entry[import org.codehaus.plexus.configuration from realm null]
import: Entry[import org.codehaus.plexus.component from realm null]
import: Entry[import org.codehaus.plexus.classworlds from realm null]
import: Entry[import org.codehaus.plexus.PlexusContainerException from realm null]
import: Entry[import org.codehaus.plexus.PlexusContainer from realm null]
import: Entry[import org.codehaus.plexus.PlexusConstants from realm null]
import: Entry[import org.codehaus.plexus.MutablePlexusContainer from realm null]
import: Entry[import org.codehaus.plexus.DuplicateChildContainerException from realm null]
import: Entry[import org.codehaus.plexus.DefaultPlexusContainer from realm null]
import: Entry[import org.codehaus.plexus.DefaultContainerConfiguration from realm null]
import: Entry[import org.codehaus.plexus.DefaultComponentRegistry from realm null]
import: Entry[import org.codehaus.plexus.ContainerConfiguration from realm null]
import: Entry[import org.codehaus.plexus.ComponentRegistry from realm null]
import: Entry[import org.codehaus.classworlds from realm null]
import: Entry[import org.apache.maven from realm null]

realm = plexus.core
strategy = org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy
urls[0] = file:/H:/Uninstall%20Softwares/eclipse/eclipse-jee-galileo-SR1-win32/eclipse/plugins/org.maven.ide.eclipse.maven_embedder_0.10.0.20100209-0800/jars/commons-cli-1.2.jar
urls[1] = file:/H:/Uninstall%20Softwares/eclipse/eclipse-jee-galileo-SR1-win32/eclipse/plugins/org.maven.ide.eclipse.maven_embedder_0.10.0.20100209-0800/jars/commons-logging-api-1.1.jar
urls[2] = file:/H:/Uninstall%20Softwares/eclipse/eclipse-jee-galileo-SR1-win32/eclipse/plugins/org.maven.ide.eclipse.maven_embedder_0.10.0.20100209-0800/jars/google-collections-1.0.jar
urls[3] = file:/H:/Uninstall%20Softwares/eclipse/eclipse-jee-galileo-SR1-win32/eclipse/plugins/org.maven.ide.eclipse.maven_embedder_0.10.0.20100209-0800/jars/jetty-client-7.0.0.v20091005.jar
urls[4] = file:/H:/Uninstall%20Softwares/eclipse/eclipse-jee-galileo-SR1-win32/eclipse/plugins/org.maven.ide.eclipse.maven_embedder_0.10.0.20100209-0800/jars/jetty-http-7.0.0.v20091005.jar
urls[5] = file:/H:/Uninstall%20Softwares/eclipse/eclipse-jee-galileo-SR1-win32/eclipse/plugins/org.maven.ide.eclipse.maven_embedder_0.10.0.20100209-0800/jars/jetty-io-7.0.0.v20091005.jar
urls[6] = file:/H:/Uninstall%20Softwares/eclipse/eclipse-jee-galileo-SR1-win32/eclipse/plugins/org.maven.ide.eclipse.maven_embedder_0.10.0.20100209-0800/jars/jetty-util-7.0.0.v20091005.jar
urls[7] = file:/H:/Uninstall%20Softwares/eclipse/eclipse-jee-galileo-SR1-win32/eclipse/plugins/org.maven.ide.eclipse.maven_embedder_0.10.0.20100209-0800/jars/log4j-1.2.12.jar
urls[8] = file:/H:/Uninstall%20Softwares/eclipse/eclipse-jee-galileo-SR1-win32/eclipse/plugins/org.maven.ide.eclipse.maven_embedder_0.10.0.20100209-0800/jars/maven-artifact-3.0-SNAPSHOT.jar
urls[9] = file:/H:/Uninstall%20Softwares/eclipse/eclipse-jee-galileo-SR1-win32/eclipse/plugins/org.maven.ide.eclipse.maven_embedder_0.10.0.20100209-0800/jars/maven-compat-3.0-SNAPSHOT.jar
urls[10] = file:/H:/Uninstall%20Softwares/eclipse/eclipse-jee-galileo-SR1-win32/eclipse/plugins/org.maven.ide.eclipse.maven_embedder_0.10.0.20100209-0800/jars/maven-core-3.0-SNAPSHOT.jar
urls[11] = file:/H:/Uninstall%20Softwares/eclipse/eclipse-jee-galileo-SR1-win32/eclipse/plugins/org.maven.ide.eclipse.maven_embedder_0.10.0.20100209-0800/jars/maven-embedder-3.0-SNAPSHOT.jar
urls[12] = file:/H:/Uninstall%20Softwares/eclipse/eclipse-jee-galileo-SR1-win32/eclipse/plugins/org.maven.ide.eclipse.maven_embedder_0.10.0.20100209-0800/jars/maven-model-3.0-SNAPSHOT.jar
urls[13] = file:/H:/Uninstall%20Softwares/eclipse/eclipse-jee-galileo-SR1-win32/eclipse/plugins/org.maven.ide.eclipse.maven_embedder_0.10.0.20100209-0800/jars/maven-model-builder-3.0-SNAPSHOT.jar
urls[14] = file:/H:/Uninstall%20Softwares/eclipse/eclipse-jee-galileo-SR1-win32/eclipse/plugins/org.maven.ide.eclipse.maven_embedder_0.10.0.20100209-0800/jars/maven-plugin-api-3.0-SNAPSHOT.jar
urls[15] = file:/H:/Uninstall%20Softwares/eclipse/eclipse-jee-galileo-SR1-win32/eclipse/plugins/org.maven.ide.eclipse.maven_embedder_0.10.0.20100209-0800/jars/maven-settings-3.0-SNAPSHOT.jar
urls[16] = file:/H:/Uninstall%20Softwares/eclipse/eclipse-jee-galileo-SR1-win32/eclipse/plugins/org.maven.ide.eclipse.maven_embedder_0.10.0.20100209-0800/jars/plexus-build-api-0.0.6.jar
urls[17] = file:/H:/Uninstall%20Softwares/eclipse/eclipse-jee-galileo-SR1-win32/eclipse/plugins/org.maven.ide.eclipse.maven_embedder_0.10.0.20100209-0800/jars/plexus-cipher-1.4.jar
urls[18] = file:/H:/Uninstall%20Softwares/eclipse/eclipse-jee-galileo-SR1-win32/eclipse/plugins/org.maven.ide.eclipse.maven_embedder_0.10.0.20100209-0800/jars/plexus-component-annotations-1.5.3.jar
urls[19] = file:/H:/Uninstall%20Softwares/eclipse/eclipse-jee-galileo-SR1-win32/eclipse/plugins/org.maven.ide.eclipse.maven_embedder_0.10.0.20100209-0800/jars/plexus-container-default-1.5.3.jar
urls[20] = file:/H:/Uninstall%20Softwares/eclipse/eclipse-jee-galileo-SR1-win32/eclipse/plugins/org.maven.ide.eclipse.maven_embedder_0.10.0.20100209-0800/jars/plexus-interpolation-1.11.jar
urls[21] = file:/H:/Uninstall%20Softwares/eclipse/eclipse-jee-galileo-SR1-win32/eclipse/plugins/org.maven.ide.eclipse.maven_embedder_0.10.0.20100209-0800/jars/plexus-sec-dispatcher-1.3.jar
urls[22] = file:/H:/Uninstall%20Softwares/eclipse/eclipse-jee-galileo-SR1-win32/eclipse/plugins/org.maven.ide.eclipse.maven_embedder_0.10.0.20100209-0800/jars/plexus-utils-2.0.1.jar
urls[23] = file:/H:/Uninstall%20Softwares/eclipse/eclipse-jee-galileo-SR1-win32/eclipse/plugins/org.maven.ide.eclipse.maven_embedder_0.10.0.20100209-0800/jars/wagon-file-1.0-beta-6.jar
urls[24] = file:/H:/Uninstall%20Softwares/eclipse/eclipse-jee-galileo-SR1-win32/eclipse/plugins/org.maven.ide.eclipse.maven_embedder_0.10.0.20100209-0800/jars/wagon-http-jetty-client-1.0-SNAPSHOT.jar
urls[25] = file:/H:/Uninstall%20Softwares/eclipse/eclipse-jee-galileo-SR1-win32/eclipse/plugins/org.maven.ide.eclipse.maven_embedder_0.10.0.20100209-0800/jars/wagon-provider-api-1.0-beta-6.jar
urls[26] = file:/H:/Uninstall%20Softwares/eclipse/eclipse-jee-galileo-SR1-win32/eclipse/plugins/org.maven.ide.eclipse.maven_embedder_0.10.0.20100209-0800/jars/xbean-reflect-3.4.jar
Number of foreign imports: 0

-----------------------------------------------------
-> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[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/PluginContainerException


==================================================


Could you please look into the error above and suggest, Thanks in advance for the quick reply.


Regards,
K Mughal.


Thanks in Advance,
Kash.
Martijn Verburg
author
Bartender

Joined: Jun 24, 2003
Posts: 3274
    
    5

The resources plugin itself needs several dependencies. I recommend you allow Maven to resolve those for you instead of manually downloading the JAR.


Cheers, Martijn - Blog,
Twitter, PCGen, Ikasan, My The Well-Grounded Java Developer book!,
My start-up.
Kashif Mughal
Ranch Hand

Joined: Jun 19, 2008
Posts: 44
Hi

Thanks for the reply, But Maven did not downloaded it automatically and complaint for the missing dependency only then I did it manually. If there is any other way please suggest.
Martijn Verburg
author
Bartender

Joined: Jun 24, 2003
Posts: 3274
    
    5

Why is it not downloading automatically? It's a core plugin....
Kashif Mughal
Ranch Hand

Joined: Jun 19, 2008
Posts: 44
Hi

I have just removed the dependency and did the maven:clean and maven:install using the m2eclipse, I am getting the following error; It also creates an updated file in the plugin folder but does not download the this dependency. But, When i installed the plugin and ran the m2eclipse first time, it downloaded some dependencies automatically but now this one.

Please let me know if I am doing something wrong.

========================


2010-06-10 16:08:10.156:INFO::Logging to StdErrLog:EBUG=false via org.eclipse.jetty.util.log.StdErrLog
2010-06-10 16:08:10.484:WARN::FAILED org.eclipse.jetty.client.SelectConnector$Manager@1636e4e: java.io.IOException: Unable to establish loopback connection
2010-06-10 16:08:10.484:WARN::FAILED org.eclipse.jetty.client.SelectConnector@df0438: java.io.IOException: Unable to establish loopback connection
2010-06-10 16:08:10.484:WARN::FAILED org.apache.maven.wagon.providers.http.FixedHttpClient@18e261d: java.io.IOException: Unable to establish loopback connection[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building Unnamed - ExpenseManager:ExpenseManager:jar:0.0.1-SNAPSHOT 0.0.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------

[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 0.953s
[INFO] Finished at: Thu Jun 10 16:08:10 BST 2010
[INFO] Final Memory: 1M/2M
[INFO] ------------------------------------------------------------------------
[ERROR] Plugin org.apache.maven.plugins:maven-resources-plugin:2.4.1 or one of its dependencies could not be resolved: Connection failed: Unable to establish loopback connection
org.apache.maven.plugins:maven-resources-plugin:maven-plugin:2.4.1

from the specified remote repositories:
central (http://mtgsiadm005:8081/nexus/content/groups/public, releases=true, snapshots=false),
snapshots (http://www.ibiblio.org/maven, releases=false, snapshots=true)
-> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[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/PluginResolutionException
Martijn Verburg
author
Bartender

Joined: Jun 24, 2003
Posts: 3274
    
    5

Right it looks like you're using Nexus to proxy requests to central, you need to ensure that it's doing that both for plugins and normal artifacts and possibly SNAPSHOTs as well. I highly recommend reading the free Nexus and Maven guides by Sonatype.

For a quick fix you might want to google that error message and see if it's mentioned in the Nexus/Maven docs online.
Kashif Mughal
Ranch Hand

Joined: Jun 19, 2008
Posts: 44
Hi

Thanks for the info, I am sending you the settings.xml , Just have a look if it rings a bell.

=========================

<?xml version="1.0" encoding="utf-8"?>
<settings
xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.or g/xsd/settin gs-1.0.0.xsd ">
<localRepository>${user.home}/.m2/repository</localRepository>
<interactiveMode>true</interactiveMode>
<usePluginRegistry>false</usePluginRegistry>
<offline>false</offline>
<servers>
<server>
<id />
<username />
<password />
<privateKey />
<passphrase />
<filePermissions />
<directoryPermissions />
<configuration />
</server>
</servers>
<profiles>
<profile>
<id>dev</id>
<activation>
<activeByDefault>false</activeByDefault>
<jdk>1.5</jdk>
<os>
<name>Windows XP</name>
<family>Windows</family>
<arch>x86</arch>
<version>5.1.2600</version>
</os>
<property>
<name>mavenVersion</name>
<value>2.0.3</value>
</property>
<file />
</activation>
<repositories>
<repository>
<id>central</id>
<url>http://repo1.maven.org/maven2</url>
<releases>
<enabled>true</enabled>
<updatePolicy>always</updatePolicy>
<checksumPolicy>warn</checksumPolicy>
</releases>
</repository>
<repository>
<id>central</id>
<url>http://repo2.maven.org/maven2</url>
<releases>
<enabled>true</enabled>
<updatePolicy>always</updatePolicy>
<checksumPolicy>warn</checksumPolicy>
</releases>
</repository>
<repository>
<id>snapshot</id>
<url>http://www.ibiblio.org/maven</url>
<releases>
<enabled>true</enabled>
<updatePolicy>always</updatePolicy>
<checksumPolicy>warn</checksumPolicy>
</releases>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>central</id>
<url>http://repo1.maven.org/maven2</url>
<snapshots>
<enabled>false</enabled>
</snapshots>
</pluginRepository>
<pluginRepository>
<id>central</id>
<url>http://repo2.maven.org/maven2</url>
<releases>
<enabled>true</enabled>
<updatePolicy>always</updatePolicy>
<checksumPolicy>warn</checksumPolicy>
</releases>
</pluginRepository>
<pluginRepository>
<id>snapshots</id>
<url>http://www.ibiblio.org/maven</url>
<releases>
<enabled>false</enabled>
</releases>
</pluginRepository>
<pluginRepository>
<id>central</id>
<url>http://mtgsiadm005:8081/nexus/content/groups/public</url>
<snapshots>
<enabled>false</enabled>
</snapshots>
</pluginRepository>
</pluginRepositories>
</profile>
</profiles>
<activeProfiles />
</settings>
Kashif Mughal
Ranch Hand

Joined: Jun 19, 2008
Posts: 44
Sorry pasted in the wrong way, Just doing it again.


Martijn Verburg
author
Bartender

Joined: Jun 24, 2003
Posts: 3274
    
    5

Right, so that tells me (I think) that as central for plugins is being served by your Nexus Repo that there's a problem contacting that Nexus repo, I'd investigate that.
Vijitha Kumara
Bartender

Joined: Mar 24, 2008
Posts: 3837

Kashif Mughal wrote:Sorry pasted in the wrong way, Just doing it again.

You can always go back and edit your post until a certain time exceeds.


SCJP 5 | SCWCD 5
[How to ask questions] [Twitter]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: ERROR] Failed to execute goal org.apache.maven.plugins:maven-resources-plugin:2.4.1:resources