Missing artifact error

From now to then, my Maven 2 started to mess around. I am using SPring STS 2.6.1 and have a single project based on Spring 3, Hibernate, DWR, Cometd and all that stuff. Today I just updated from ...

From now to then, my Maven 2 started to mess around.

I am using SPring STS 2.6.1 and have a single project based on Spring 3, Hibernate, DWR, Cometd and all that stuff.

Today I just updated from Git und all of a sudden, I got that scary mvn exclamation mark (!) next to my project.

After hitting «Project -> Maven -> Update dependencies» I just receive:

24.05.11 15:26:58 MESZ: Missing artifact org.jdom:jdom:jar:1.1:compile
24.05.11 15:26:58 MESZ: Missing artifact org.apache.solr:solr-common:jar:1.3.0:compile
24.05.11 15:26:58 MESZ: Missing artifact org.apache.solr:solr-core:jar:1.3.0:compile
24.05.11 15:26:58 MESZ: Missing artifact org.apache.solr:solr-solrj:jar:1.3.0:compile
24.05.11 15:26:58 MESZ: Missing artifact stax:stax:jar:1.2.0:compile
24.05.11 15:26:58 MESZ: Missing artifact stax:stax-api:jar:1.0.1:compile
24.05.11 15:26:58 MESZ: Missing artifact org.apache.solr:solr-lucene-analyzers:jar:1.3.0:compile
24.05.11 15:26:58 MESZ: Missing artifact org.apache.solr:solr-lucene-core:jar:1.3.0:compile
24.05.11 15:26:58 MESZ: Missing artifact org.apache.solr:solr-lucene-highlighter:jar:1.3.0:compile
24.05.11 15:26:58 MESZ: Missing artifact org.apache.solr:solr-lucene-queries:jar:1.3.0:compile
24.05.11 15:26:58 MESZ: Missing artifact org.apache.solr:solr-lucene-snowball:jar:1.3.0:compile
24.05.11 15:26:58 MESZ: Missing artifact org.apache.solr:solr-lucene-spellchecker:jar:1.3.0:compile
24.05.11 15:26:58 MESZ: Missing artifact commons-httpclient:commons-httpclient:jar:3.1:compile
24.05.11 15:26:58 MESZ: Missing artifact org.apache.commons:commons-io:jar:1.3.2:compile
24.05.11 15:26:58 MESZ: Missing artifact commons-logging:commons-logging:jar:1.0.4:compile
24.05.11 15:26:58 MESZ: Missing artifact org.apache.solr:solr-commons-csv:jar:1.3.0:compile
24.05.11 15:26:58 MESZ: Missing artifact org.apache.geronimo.specs:geronimo-stax-api_1.0_spec:jar:1.0.1:compile
24.05.11 15:26:58 MESZ: Missing artifact net.java.dev.stax-utils:stax-utils:jar:20040917:compile
24.05.11 15:26:58 MESZ: Missing artifact org.apache.lucene:lucene-snowball:jar:2.4.1:compile
24.05.11 15:26:58 MESZ: Missing artifact org.apache.lucene:lucene-core:jar:2.4.1:compile
24.05.11 15:26:58 MESZ: Missing artifact org.slf4j:slf4j-api:jar:1.6.1:compile
24.05.11 15:26:58 MESZ: Missing artifact org.springframework:spring-expression:jar:3.0.5.RELEASE:compile
24.05.11 15:26:58 MESZ: Missing artifact org.springframework:spring-core:jar:3.0.5.RELEASE:compile
24.05.11 15:26:58 MESZ: Missing artifact org.springframework:spring-beans:jar:3.0.5.RELEASE:compile
24.05.11 15:26:58 MESZ: Missing artifact org.springframework:spring-aop:jar:3.0.5.RELEASE:compile
24.05.11 15:26:58 MESZ: Missing artifact aopalliance:aopalliance:jar:1.0:compile
24.05.11 15:26:58 MESZ: Missing artifact org.springframework:spring-asm:jar:3.0.5.RELEASE:compile
24.05.11 15:26:58 MESZ: Missing artifact org.springframework:spring-aspects:jar:3.0.5.RELEASE:compile
24.05.11 15:26:58 MESZ: Missing artifact org.springframework:spring-test:jar:3.0.5.RELEASE:compile
24.05.11 15:26:58 MESZ: Missing artifact org.springframework:spring-context:jar:3.0.5.RELEASE:compile
24.05.11 15:26:58 MESZ: Missing artifact org.springframework:spring-context-support:jar:3.0.5.RELEASE:compile
24.05.11 15:26:58 MESZ: Missing artifact org.springframework:spring-tx:jar:3.0.5.RELEASE:compile
24.05.11 15:26:58 MESZ: Missing artifact org.springframework:spring-jdbc:jar:3.0.5.RELEASE:compile
24.05.11 15:26:58 MESZ: Missing artifact org.springframework:spring-orm:jar:3.0.5.RELEASE:compile
24.05.11 15:26:58 MESZ: Missing artifact org.springframework:spring-oxm:jar:3.0.5.RELEASE:compile
24.05.11 15:26:58 MESZ: Missing artifact org.springframework:spring-web:jar:3.0.5.RELEASE:compile
24.05.11 15:26:58 MESZ: Missing artifact org.springframework:spring-webmvc:jar:3.0.5.RELEASE:compile
24.05.11 15:26:58 MESZ: Missing artifact org.springframework:spring-instrument:jar:3.0.5.RELEASE:compile
24.05.11 15:26:58 MESZ: Missing artifact org.springframework.security:spring-security-core:jar:3.0.5.RELEASE:compile
24.05.11 15:26:58 MESZ: Missing artifact org.springframework.security:spring-security-web:jar:3.0.5.RELEASE:compile
24.05.11 15:26:58 MESZ: Missing artifact org.springframework.security:spring-security-taglibs:jar:3.0.5.RELEASE:compile
24.05.11 15:26:58 MESZ: Missing artifact org.springframework.security:spring-security-acl:jar:3.0.5.RELEASE:compile
24.05.11 15:26:58 MESZ: Missing artifact org.springframework.security:spring-security-parent:pom:3.0.5.RELEASE:compile
24.05.11 15:26:58 MESZ: Missing artifact org.springframework.security:spring-security-config:jar:3.0.5.RELEASE:system
24.05.11 15:26:58 MESZ: Missing artifact org.hibernate:hibernate-core:jar:3.3.2.GA:compile
24.05.11 15:26:58 MESZ: Missing artifact antlr:antlr:jar:2.7.6:compile
24.05.11 15:26:58 MESZ: Missing artifact commons-collections:commons-collections:jar:3.1:compile
24.05.11 15:26:58 MESZ: Missing artifact dom4j:dom4j:jar:1.6.1:compile
24.05.11 15:26:58 MESZ: Missing artifact javax.transaction:jta:jar:1.1:compile
24.05.11 15:26:58 MESZ: Missing artifact org.hibernate:hibernate-annotations:jar:3.4.0.GA:compile
24.05.11 15:26:58 MESZ: Missing artifact org.hibernate:ejb3-persistence:jar:1.0.2.GA:compile
24.05.11 15:26:58 MESZ: Missing artifact org.hibernate:hibernate-commons-annotations:jar:3.1.0.GA:compile
24.05.11 15:26:58 MESZ: Missing artifact org.hibernate:ejb3-persistence:pom:1.0.2.GA:compile
24.05.11 15:26:58 MESZ: Missing artifact commons-dbcp:commons-dbcp:jar:1.4:compile
24.05.11 15:26:58 MESZ: Missing artifact commons-pool:commons-pool:jar:1.5.4:compile
24.05.11 15:26:58 MESZ: Missing artifact org.aspectj:aspectjweaver:jar:1.6.10:compile
24.05.11 15:26:58 MESZ: Missing artifact org.slf4j:slf4j-log4j12:jar:1.6.1:compile
24.05.11 15:26:58 MESZ: Missing artifact log4j:log4j:jar:1.2.16:compile
24.05.11 15:26:58 MESZ: Missing artifact javax.persistence:persistence-api:jar:1.0:compile
24.05.11 15:26:58 MESZ: Missing artifact javassist:javassist:jar:3.12.1.GA:compile
24.05.11 15:26:58 MESZ: Missing artifact postgresql:postgresql:jar:9.0-801.jdbc4:compile
24.05.11 15:26:58 MESZ: Missing artifact commons-codec:commons-codec:jar:1.4:compile
24.05.11 15:26:58 MESZ: Missing artifact org.directwebremoting:dwr:jar:2.0.3:compile
24.05.11 15:26:58 MESZ: Missing artifact org.beanshell:bsh:jar:2.0b4:compile
24.05.11 15:26:58 MESZ: Missing artifact org.jasypt:jasypt:jar:1.7:compile
24.05.11 15:26:58 MESZ: Missing artifact cglib:cglib:jar:2.2:compile
24.05.11 15:26:58 MESZ: Missing artifact asm:asm:jar:3.1:compile
24.05.11 15:26:58 MESZ: Missing artifact commons-fileupload:commons-fileupload:jar:1.2.2:compile
24.05.11 15:26:58 MESZ: Missing artifact org.apache.poi:poi:jar:3.8-beta1:compile
24.05.11 15:26:58 MESZ: Missing artifact jasperreports:jasperreports:jar:3.5.3:compile
24.05.11 15:26:58 MESZ: Missing artifact commons-beanutils:commons-beanutils:jar:1.8.0:compile
24.05.11 15:26:58 MESZ: Missing artifact commons-digester:commons-digester:jar:1.7:compile
24.05.11 15:26:58 MESZ: Missing artifact jfree:jcommon:jar:1.0.15:compile
24.05.11 15:26:58 MESZ: Missing artifact jfree:jfreechart:jar:1.0.12:compile
24.05.11 15:26:58 MESZ: Missing artifact xml-apis:xml-apis:jar:1.3.02:compile
24.05.11 15:26:58 MESZ: Missing artifact eclipse:jdtcore:jar:3.1.0:compile
24.05.11 15:26:58 MESZ: Missing artifact junit:junit:jar:4.8.2:test
24.05.11 15:26:58 MESZ: Missing artifact org.easymock:easymock:jar:3.0:test
24.05.11 15:26:58 MESZ: Missing artifact cglib:cglib-nodep:jar:2.2:test
24.05.11 15:26:58 MESZ: Missing artifact org.objenesis:objenesis:jar:1.2:test
24.05.11 15:26:58 MESZ: Missing artifact net.sf.ehcache:ehcache:pom:2.3.1:compile
24.05.11 15:26:58 MESZ: Missing artifact net.sf.ehcache:ehcache-core:jar:2.3.1:compile
24.05.11 15:26:58 MESZ: Missing artifact net.sf.ehcache:ehcache-terracotta:jar:2.3.1:compile
24.05.11 15:26:58 MESZ: Missing artifact org.opensymphony.quartz:quartz-all:jar:1.6.1:compile
24.05.11 15:26:58 MESZ: Missing artifact javax.servlet:jstl:jar:1.1.2:compile
24.05.11 15:26:58 MESZ: Missing artifact taglibs:standard:jar:1.1.2:compile
24.05.11 15:26:58 MESZ: Missing artifact org.aspectj:aspectjrt:jar:1.6.5:compile
24.05.11 15:26:58 MESZ: Missing artifact org.apache.velocity:velocity:jar:1.6.2:compile
24.05.11 15:26:58 MESZ: Missing artifact commons-lang:commons-lang:jar:2.4:compile
24.05.11 15:26:58 MESZ: Missing artifact oro:oro:jar:2.0.8:compile
24.05.11 15:26:58 MESZ: Missing artifact javax.mail:mail:jar:1.4.1:compile
24.05.11 15:26:58 MESZ: Missing artifact javax.activation:activation:jar:1.1:compile
24.05.11 15:26:58 MESZ: Missing artifact com.lowagie:itext:jar:2.0.7:compile
24.05.11 15:26:58 MESZ: Missing artifact bouncycastle:bcmail-jdk14:jar:138:compile
24.05.11 15:26:58 MESZ: Missing artifact bouncycastle:bcprov-jdk14:jar:138:compile
24.05.11 15:26:58 MESZ: Missing artifact org.cometd.java:cometd-java-server:jar:1.0.1:compile
24.05.11 15:26:58 MESZ: Missing artifact org.cometd.java:cometd-api:jar:1.0.1:compile
24.05.11 15:26:58 MESZ: Missing artifact org.eclipse.jetty:jetty-util:jar:7.0.1.v20091125:compile
24.05.11 15:26:58 MESZ: Missing artifact org.eclipse.jetty:jetty-continuation:jar:7.0.1.v20091125:compile
24.05.11 15:26:58 MESZ: Missing artifact org.apache.velocity:velocity-tools:jar:2.0:compile
24.05.11 15:26:58 MESZ: Missing artifact commons-chain:commons-chain:jar:1.1:compile
24.05.11 15:26:58 MESZ: Missing artifact commons-validator:commons-validator:jar:1.3.1:compile
24.05.11 15:26:58 MESZ: Missing artifact sslext:sslext:jar:1.2-0:compile
24.05.11 15:26:58 MESZ: Missing artifact org.apache.struts:struts-core:jar:1.3.8:compile
24.05.11 15:26:58 MESZ: Missing artifact org.apache.struts:struts-taglib:jar:1.3.8:compile
24.05.11 15:26:58 MESZ: Missing artifact org.apache.struts:struts-tiles:jar:1.3.8:compile
24.05.11 15:26:58 MESZ: Missing artifact net.htmlparser.jericho:jericho-html:jar:3.1:compile
24.05.11 15:26:58 MESZ: Missing artifact ro.isdc.wro4j:wro4j-core:jar:1.3.3:compile
24.05.11 15:26:58 MESZ: Missing artifact commons-io:commons-io:jar:2.0:compile
24.05.11 15:26:58 MESZ: Missing artifact com.google.collections:google-collections:jar:1.0:compile
24.05.11 15:26:58 MESZ: Missing artifact javax.servlet:servlet-api:jar:2.5:compile
24.05.11 15:26:58 MESZ: Missing artifact redis.clients:jedis:jar:1.5.2:compile
24.05.11 15:26:58 MESZ: Missing artifact org.mongodb:mongo-java-driver:jar:2.5.2:compile
24.05.11 15:26:58 MESZ: Missing artifact org.xhtmlrenderer:core-renderer:jar:R8pre2:compile
24.05.11 15:26:58 MESZ: Missing artifact org.apache.sanselan:sanselan:jar:0.97-incubator:compile
24.05.11 15:26:58 MESZ: Missing artifact com.kenai.nbpwr:com-sun-pdfview:jar:1.0.5-201003191900:compile
24.05.11 15:26:58 MESZ: Missing artifact org.swinglabs:pdf-renderer:jar:1.0.5:compile
24.05.11 15:26:58 MESZ: Missing artifact org.safehaus.jug:jug:jar:2.0.0:system
24.05.11 15:26:58 MESZ: Missing artifact de.dankomannhaupt:JDBCAppender:jar:1.0:system
24.05.11 15:26:58 MESZ: Missing artifact spy:memcahed:jar:2.5:system
24.05.11 15:26:58 MESZ: Missing artifact net.sf.beanlib:beanlib:jar:5.0.2beta:compile
24.05.11 15:26:58 MESZ: Missing artifact xstream:xstream:jar:1.1.2:compile
24.05.11 15:26:58 MESZ: Missing artifact net.jcip:jcip-annotations:jar:1.0:compile
24.05.11 15:26:58 MESZ: Missing artifact net.sf.beanlib:beanlib-hibernate:jar:5.0.2beta:compile

My pom.xml looks like:

<properties>
        <org.springframework.version>3.0.5.RELEASE</org.springframework.version>
        <hibernate.version>3.3.2.GA</hibernate.version>
    </properties>

    <repositories>
        <repository>
            <id>JBoss</id>
            <name>JBoss Repsitory</name>
            <layout>default</layout>
            <url>http://repository.jboss.org/maven2</url>
        </repository>
    </repositories>
    <!-- Bezeichnung -->
    <artifactId>project-dao</artifactId>
    <name>Vevention Dao</name>
    <groupId>com.corp.dao</groupId>
    <version>1.0Beta</version>

    <dependencies>
        <dependency>
          <groupId>org.springframework</groupId>
          <artifactId>spring-expression</artifactId>
          <version>${org.springframework.version}</version>
        </dependency>
        <dependency>
          <groupId>org.springframework</groupId>
          <artifactId>spring-beans</artifactId>
          <version>${org.springframework.version}</version>
        </dependency>
        <dependency>
          <groupId>org.springframework</groupId>
          <artifactId>spring-aop</artifactId>
          <version>${org.springframework.version}</version>
        </dependency>
        <dependency>
          <groupId>org.springframework</groupId>
          <artifactId>spring-aspects</artifactId>
          <version>${org.springframework.version}</version>
        </dependency>
        <dependency>
          <groupId>org.springframework</groupId>
          <artifactId>spring-context</artifactId>
          <version>${org.springframework.version}</version>
        </dependency>
        <dependency>
          <groupId>org.springframework</groupId>
          <artifactId>spring-context-support</artifactId>
          <version>${org.springframework.version}</version>
        </dependency>
        <dependency>
          <groupId>org.springframework</groupId>
          <artifactId>spring-tx</artifactId>
          <version>${org.springframework.version}</version>
        </dependency>
        <dependency>
          <groupId>org.springframework</groupId>
          <artifactId>spring-jdbc</artifactId>
          <version>${org.springframework.version}</version>
        </dependency>
        <dependency>
          <groupId>org.springframework</groupId>
          <artifactId>spring-orm</artifactId>
          <version>${org.springframework.version}</version>
        </dependency>
        <dependency>
          <groupId>org.springframework</groupId>
          <artifactId>spring-oxm</artifactId>
          <version>${org.springframework.version}</version>
        </dependency>
        <dependency>
          <groupId>org.springframework</groupId>
          <artifactId>spring-web</artifactId>
          <version>${org.springframework.version}</version>
        </dependency>
        <dependency>
          <groupId>org.springframework</groupId>
          <artifactId>spring-webmvc</artifactId>
          <version>${org.springframework.version}</version>
        </dependency>
        <dependency> 
            <groupId>org.springframework</groupId>
            <artifactId>spring-instrument</artifactId>
            <version>${org.springframework.version}</version>
        </dependency>
        <dependency>
            <groupId>org.springframework.security</groupId>
            <artifactId>spring-security-core</artifactId>
            <version>${org.springframework.version}</version>
         </dependency>
         <dependency>
            <groupId>org.springframework.security</groupId>
            <artifactId>spring-security-web</artifactId>
            <version>${org.springframework.version}</version>
         </dependency>
         <dependency>
            <groupId>org.springframework.security</groupId>
            <artifactId>spring-security-taglibs</artifactId>
            <version>${org.springframework.version}</version>
         </dependency>
        <dependency> 
            <groupId>org.springframework.security</groupId>
            <artifactId>spring-security-config</artifactId>
            <version>${org.springframework.version}</version>
            <scope>system</scope> 
            <systemPath>${basedir}/lib/spring-security-config-3.0.5.RELEASE.jar</systemPath> 
        </dependency>

        <dependency>
            <groupId>javax.servlet</groupId>
            <artifactId>servlet-api</artifactId>
            <version>2.5</version>
        </dependency>         

        <dependency>
            <groupId>org.hibernate</groupId>
            <artifactId>hibernate-core</artifactId>
            <version>${hibernate.version}</version>
        </dependency>
        <dependency>
            <groupId>org.hibernate</groupId>
            <artifactId>hibernate-annotations</artifactId>
            <version>3.4.0.GA</version>
        </dependency>
        <dependency>
            <groupId>org.hibernate</groupId>
            <artifactId>ejb3-persistence</artifactId>
            <version>1.0.2.GA</version>
            <type>pom</type>
        </dependency>
<dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>slf4j-log4j12</artifactId>
            <version>1.6.1</version>
        </dependency>
        <dependency>
            <groupId>commons-logging</groupId>
            <artifactId>commons-logging</artifactId>
            <version>1.1.1</version>
        </dependency>
        <dependency>
            <groupId>commons-dbcp</groupId>
            <artifactId>commons-dbcp</artifactId>
            <version>1.4</version>
        </dependency>
        <dependency>
            <groupId>jdom</groupId>
            <artifactId>jdom</artifactId>
            <version>1.1</version>
        </dependency>
        <dependency>
            <groupId>commons-lang</groupId>
            <artifactId>commons-lang</artifactId>
            <version>2.4</version>
        </dependency>
        <dependency>
            <groupId>org.hibernate</groupId>
            <artifactId>hibernate-search</artifactId>
            <version>3.1.0.GA</version>
        </dependency>
        <dependency>
            <groupId>org.apache.solr</groupId>
            <artifactId>solr-common</artifactId>
            <version>1.3.0</version>
        </dependency>
        <dependency>
            <groupId>org.apache.solr</groupId>
            <artifactId>solr-core</artifactId>
            <version>1.3.0</version>
        </dependency>
        <dependency>
            <groupId>org.apache.lucene</groupId>
            <artifactId>lucene-snowball</artifactId>
            <version>2.4.1</version>
        </dependency>
        <dependency>
            <groupId>javax.transaction</groupId>
            <artifactId>jta</artifactId>
            <version>1.0.1B</version>
        </dependency>
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>4.4</version>
        </dependency>
        <dependency>
            <groupId>org.springframework</groupId>
            <artifactId>spring-test</artifactId>
            <version>2.5.6.SEC01</version>
        </dependency>
        <dependency>
            <groupId>memcached</groupId>
            <artifactId>memcached</artifactId>
            <version>2.3.1</version>
        </dependency>
        <dependency>
            <groupId>org.aspectj</groupId>
            <artifactId>aspectjrt</artifactId>
            <version>1.6.5</version>
        </dependency>
         <dependency>
            <groupId>redis.clients</groupId>
            <artifactId>jedis</artifactId>
            <version>1.5.2</version>
        </dependency>       

        <dependency>
            <groupId>voldemort</groupId>
            <artifactId>voldemort</artifactId>
            <version>0.81</version>
        </dependency>

    </dependencies>
</project>

I then checked on my Mac /Users/XYZ/.m2 and all jar files are in place as expected.

I am using the current Maven release shipped with STS. I also enabled debug output but there was nothing suspicious.

ROMANIA_engineer's user avatar

asked May 24, 2011 at 13:47

Jannick's user avatar

1

There are a few other options apart from Project->Clean, some of which are more along the lines of turning it off and on again.

  • Try right-clicking on the project and selecting Maven->Update Project Configuration.
  • Disable then re-enable dependency management (right-click Maven->Disable Dependency Management then Maven->Enable Dependency Management
  • Close the project and reopen it.
  • Check that your Maven settings are configured correctly. If you are behind a proxy you’ll need to configure the proxy settings in the global or user settings.
  • Check you’re using the Maven installation you expect. By default m2eclipse uses the embedder, if you have a separate installation you may want to configure m2eclipse to use the external installation so that CLI and Eclipse builds are consistent. This also ensures you’re configured to connect through any proxy as above.

zb226's user avatar

zb226

9,2426 gold badges48 silver badges77 bronze badges

answered May 24, 2011 at 14:48

Rich Seller's user avatar

Rich SellerRich Seller

82.6k23 gold badges170 silver badges176 bronze badges

2

I received this same issue on SpringSource Tools ver 2.8.0.RELEASE. I had to do Maven -> Update Maven Dependencies and check the option for «Force Update of Snapshot/Releases».

answered Nov 18, 2011 at 17:35

cracked_all's user avatar

cracked_allcracked_all

1,3311 gold badge11 silver badges26 bronze badges

0

I encountered similar issue. The missing artifacts (jar files) exists in ~/.m2 directory and somehow eclipse is unable to find it.

For example:
Missing artifact org.jdom:jdom:jar:1.1:compile

I looked through this directory ~/.m2/repository/org/jdom/jdom/1.1 and I noticed there is this file _maven.repositories. I opened it using text editor and saw the following entry:

#NOTE: This is an internal implementation file, its format can be changed without prior notice.
#Wed Feb 13 17:12:29 SGT 2013
jdom-1.1.jar>central=
jdom-1.1.pom>central=

I simply removed the «central» word from the file:

#NOTE: This is an internal implementation file, its format can be changed without prior notice.
#Wed Feb 13 17:12:29 SGT 2013
jdom-1.1.jar>=
jdom-1.1.pom>=

and run Maven > Update Project from eclipse and it just worked :)
Note that your file may contain other keyword instead of «central».

answered Jun 27, 2013 at 17:58

maxhuang's user avatar

maxhuangmaxhuang

2,5611 gold badge20 silver badges26 bronze badges

6

I had the same problem. Rich Seller’s solution didn’t work for my situation, I fixed it by cancel the Window -> Preferences -> Maven. Do not automatically update dependencies from remote repositories option, then right-clicking on the project and selecting Maven->Update Project.

Abdul Rahman's user avatar

Abdul Rahman

2,0874 gold badges28 silver badges36 bronze badges

answered Aug 1, 2012 at 6:43

dongpf's user avatar

dongpfdongpf

1,50716 silver badges8 bronze badges

1

I had similar problem. it was showing error «Missing artifact……».After digging in, I found that I have proxy settings enabled which should be configured (proxyname, user/pwd) in setting.xml inside conf folder of Maven. As a resolution go to
Eclipse….Windows->preferences->Maven->UserSettings….and update the user setting to point the setting.xml which you have inside conf folder of Maven. After that go to Project->Update All Maven Dependencies. It should work fine after the build.

Ben's user avatar

Ben

53.5k48 gold badges176 silver badges224 bronze badges

answered Oct 31, 2011 at 9:52

kunal Singh's user avatar

2

I was facing the same error with Spring Boot dependencies. What solved for me was letting Maven resolve the dependencies wrapping them with dependency management:

<parent>
    <groupId>org.springframework.boot</groupId>
    <artifactId>spring-boot-starter-parent</artifactId>
    <version>1.3.0.RELEASE</version>
</parent>

<dependencyManagement>
    <dependencies>
      <dependency>...</dependency>
      ...
    </dependencies>
</dependencyManagement>

answered Jan 5, 2016 at 18:59

cmjunior's user avatar

cmjuniorcmjunior

1411 silver badge5 bronze badges

2

Wow, this had me tearing my hair out, banging my head against walls, tables and other things.
I had the same or a similar issue as the OP where it was either missing / not downloading the jar files or downloading them, but not including them in the Maven dependencies with the same error message.
My limited knowledge of java packaging and maven probably didn’t help.

For me the problem seems to have been caused by the Dependency Type «bundle» (but I don’t know how or why). I was using the Add Dependency dialog in Eclipse Mars on the pom.xml, which allows you to search and browse the central repository. I was searching and adding a dependency to jackson-core libraries, picking the latest version, available as a bundle. This kept failing.

So finally, I changed the dependency properties form bundle to jar (again using the dependency properties window), which finally downloaded and referenced the dependencies properly after saving the changes.

answered Jul 27, 2016 at 14:18

Ben's user avatar

BenBen

1,5091 gold badge17 silver badges20 bronze badges

1

Finally, it turned out to be a missing artifact of solr that seemed to block all the rest of my build cycle.

I have no idea why mvn behaves like that, but upgrading to the latest version fixed it.

ROMANIA_engineer's user avatar

answered May 26, 2011 at 13:13

Jannick's user avatar

JannickJannick

2,0942 gold badges17 silver badges20 bronze badges

M2Eclipse sometimes does that. Select Project > Clean ... from the Menu and everything will be fine after the rebuild

answered May 24, 2011 at 13:51

Sean Patrick Floyd's user avatar

1

I had the similar problem. Just after adding below dependency

<dependency>
    <groupId>xerces</groupId>
    <artifactId>xercesImpl</artifactId>
    <version>2.9.1</version>
    <type>bundle</type>
</dependency>

caused the problem. I deleted that dependency even then I’m getting the same error. I don’t know what happened. I tried updating the maven dependency configuration which solved my issue.

answered Oct 26, 2012 at 6:40

Raviteja Gubba's user avatar

After not much success with any of the answers available here so far.

My solution:

I downloaded the jar file manually and then installed the dependency by using Apache Maven install:install-file plugin, see more details here

A Full Example:

<dependency>
     <groupId>commons-net</groupId>
     <artifactId>commons-net</artifactId>
     <version>3.4</version>
</dependency>
  1. Download jar file from here

  2. Install it by using the following command:

mvn -X install:install-file " -DgroupId=commons-net" "-DartifactId=commons-net" "-Dversion=3.4" "-Dpackaging=jar" "-Dfile={your_full_downloads_path}/commons-net-3.4.jar"

  1. Click on the project and select Maven->Update Project

Shreyas's user avatar

Shreyas

9596 silver badges19 bronze badges

answered Apr 1, 2016 at 20:11

emecas's user avatar

emecasemecas

1,5863 gold badges31 silver badges42 bronze badges

i download the missing jar and placed in the .m2 repository fixed the problem =]

answered Feb 15, 2013 at 22:08

winston's user avatar

1

I had the same problem, maven was complaining about a missing artifact, even though it existed in .m2/repository/[…]. In my case the problem was that I forgot to specify the correct repository in the pom.xml from which the package was downloaded originally (download by another project).

Adding the package repository to the pom.xml solved the problem.

<repositories>
  <repository>
    <id>SomeName</id>
    <name>SomeName</name>
    <url>http://url.to.repo</url>
  </repository>
</repositories>

Thanks Maximilianus for the hint to those «*.repositories» files in the package directory.

Community's user avatar

answered Mar 17, 2016 at 10:58

Exocom's user avatar

ExocomExocom

7812 gold badges8 silver badges24 bronze badges

Ohh what a mess! My advise: When its comes to messy poms or project packaging, Eclipse is really bad at showing the real problem. It will tell you some dependencies are missing, when in fact for pom is malformed or some other problem are present in your pom.

Leave Eclipse alone are run a maven install. You will get to the real problem really quick!

answered Feb 12, 2018 at 14:50

pmartin8's user avatar

pmartin8pmartin8

1,5151 gold badge19 silver badges36 bronze badges

1

As i tried all above as my friends said but nothing worked actually, I was facing same problem and found solution in some different way my issue starts when i added below repository

<dependency>
  <groupId>dom4j</groupId>
  <artifactId>dom4j</artifactId>
  <version>20040902.021138</version>
</dependency>

and my problem starts…so then i changed the version and took previous version and it removed all error. So i think this issue can because of the version we are adding in POM.xml file.

j0k's user avatar

j0k

22.4k28 gold badges80 silver badges89 bronze badges

answered Aug 23, 2012 at 0:19

Tapan Upadhyay's user avatar

The following steps worked for me.

1) Cut all the contents from pom.xml file and keep it another file and save the pom.xml
2) Just delete .m2 folder(entire maven repository) and restart the eclipse(or jbdevstudio)
3) paste the previous pom.xml file content(from the cut file) and all the error are gone.

answered Jun 9, 2014 at 9:05

user2142969's user avatar

1

I was facing the same issue and below step removed all these errors :

  • Right click Project -> Maven -> Update Project

Boris Brodski's user avatar

answered Jun 25, 2015 at 9:13

Sanchi Girotra's user avatar

I used the below code in pom.xml to download the jar

<dependency>
            <groupId>javax.validation</groupId>
            <artifactId>validation-api</artifactId>
            <version>1.1.0.FINAL</version>
</dependency>

But in the .m2 folder under validation folder…the jar didnt get downloaded. I am not sure about the issue. But i downloaded the same jar from maven official website and placed in the .m2 folder under respective folder and cleaned the project. The error gone and it started working now.

answered Mar 22, 2016 at 12:00

Vikram R's user avatar

Vikram RVikram R

992 silver badges8 bronze badges

My case following procedure solve the issue

1- enter image description here

2- check the active profile
enter image description here

answered Aug 21, 2014 at 7:01

0xFK's user avatar

0xFK0xFK

2,41331 silver badges24 bronze badges

I faced this problem a couple of times. The following solution worked for me.

  1. copy the existing pom file as a back up, and delete the dependency that’s causing this error. delete the contents of the folder which this artifact is referring to.
  2. add the deleted dependency in the pom again and add the jar files in that folder.
  3. do a Maven->update Project. The errors will go away.

As a side note, sometimes when you’re copying files from some other computer there may be encryption.

Pang's user avatar

Pang

9,365146 gold badges85 silver badges121 bronze badges

answered Feb 24, 2015 at 9:19

Sharath Mareddy's user avatar

I had a similar solution like @maximilianus. The difference was that my .repositories files were called _remote.repositores and I had to delete them to make it work.

For eg in my case I deleted

  • C:UsersUSERNAME.m2repositoryjtajta1.0.1_remote.repositories and
  • C:UsersUSERNAME.m2repositoryjndijndi1.2.1_remote.repositories

After doing so my errors disappeared.

answered Mar 12, 2015 at 22:18

derFunk's user avatar

derFunkderFunk

1,5772 gold badges20 silver badges31 bronze badges

I was getting a similar problem with SBT and slf4j. Nothing had changed, but on one machine it suddenly wouldn’t build.

I tried:

  • sbt clean
  • deleting target/
  • deleting project working directory and doing a fresh checkout/build
  • deleting the ~/.sbt/<scala-version>/ folder
  • deleting the offending slf4j folder from the ~/.ivy2 cache
  • placing the missing slf4j jars in the expected ivy2 folder

None of the above worked.

So, I had to bite the bullet and delete my entire ~/.ivy2/ cache folder and wait for 2GB of dependencies to be downloaded again. I’m not familiar with what sort of cache manifests get written in there, but this must have been a corruption of one of them.

(using SBT 2.10.4 for Spark builds)

answered Oct 18, 2015 at 16:41

Joseph Lust's user avatar

Joseph LustJoseph Lust

18.9k7 gold badges81 silver badges76 bronze badges

If the other solutions didn’t work and you know the correct jars are in your repository then:

The problem is that eclipse caches the errors for some reason.

I solved this problem by deleting the errors in the Problems tab and then I refreshed the project explorer and all the exclamation points and errors never returned.

answered Jan 5, 2016 at 19:39

djm's user avatar

djmdjm

3422 silver badges13 bronze badges

I have seen a bug that manifested as «Error installing artifact: File ../null/… does not exist» (that is, the file was not found because there was «null» in the path). The reason was that one environment variable was not visible to maven. It was:

JV_SRCROOT=$DIRECTORY

instead of

export JV_SRCROOT=$DIRECTORY

(in the latter case the variable is visible to child processes)

answered Jul 5, 2017 at 15:20

18446744073709551615's user avatar

After running eclipse:clean eclipse:eclipse its worked for me.
enter image description here

answered Mar 19, 2018 at 5:14

Santhosh Hirekerur's user avatar

Just in order to provide one more possible solution: In my case, I removed «central» from .m2/jdom/jdom/1.0 settings, and did everything else, without results.

So I discovered my settings.xml in ./m2 folder was stuck by a failed process. As I didn’t found the process in the system task manager, I restarted the computer and it worked.

answered Mar 20, 2018 at 18:54

Alex's user avatar

AlexAlex

3,29511 gold badges50 silver badges79 bronze badges

If nothing else works which was the case for me, in the problems view, right click and copy the errors and paste it in a text editor. And scroll down to see if there are other errors besides just the missing artifact.

Eclipse problems view only shows about 100 errors and the errors that are not visible might be the ones that’s causing all the other missing artifact errors.

Once I saw all the errors, I was able to figure out what the issue was and fixed it.

answered Jul 20, 2018 at 17:19

leventgo's user avatar

leventgoleventgo

1091 gold badge1 silver badge5 bronze badges

I have tried many tips but the only one that works is this one. Update the Maven configuration. Right-click on pom.xml, Run as -> Maven build (the 2nd one). Enter «clean package» in the Goals fields. Check the Skip Tests box. Then Run, it will properly download all the jars and the problem is fixed.

answered Nov 13, 2018 at 19:12

MariemJab's user avatar

MariemJabMariemJab

6798 silver badges13 bronze badges

I tried all of the above solutions except manually installing jar in my repository.

By deleting the _remote_repositories file in the same directory as the «missing jar file» and doing maven update I got it to work.

This is the same end result as manually installing, I presume.

answered Jan 31, 2019 at 11:42

user939857's user avatar

user939857user939857

3494 silver badges18 bronze badges

My problem: I forgot to import a newly added project (added by my co-worker) into my eclipse workspace.

File > Import > Maven > Existing Maven Projects, find it in the dir-tree, check the single non-ghosted one which is not already added.

Details: My co-worker had added a new project which was a git submodule. Existing projects referred to it in their pom.xml. I had already done «git submodule init» and «git submodule update». mvn built fine from the command-line but I kept getting this «Missing artifact» error in eclipse pointing at the top of my pom.xml.

answered Aug 29, 2019 at 16:39

Curtis Yallop's user avatar

Curtis YallopCurtis Yallop

6,3783 gold badges44 silver badges33 bronze badges

In this example, we will be discussing about how to resolve “Missing Artifact” error while using Maven. Before we start with this article, it is expected that we have a basic understanding of how software development works with Java. It would also be good if we have an exposure to software build and deployment process to understand the usage and the working of the Apache Maven better. To get familiar with the installation, the usage and the basics of Maven please refer to the article Maven Hello World.

In this example, we will see how to resolve “Missing artifact error” while working with Maven.

1. Introduction

In general software terms, an artifact is something produced by the software development process, whether it is software related documentation or an executable file.

In Maven terminology, an artifact is a file, usually a JAR, that gets deployed to a Maven repository. It is a resource generated by a maven project. Each maven project can have exactly one artifact like a jar, war, ear, etc. Each artifact has a group ID (usually a reversed domain name, like com.jcg.maven), an artifact ID (just a name), and a version string. The three together uniquely identify the artifact. You can refer to the pom.xml below.

pom.xml

<project 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.org/maven-v4_0_0.xsd">
 <modelVersion>4.0.0</modelVersion>
 <groupId>com.jcg.maven</groupId>
 <artifactId>MavenHelloWorldProject</artifactId>
 <packaging>jar</packaging>
 <version>1.0-SNAPSHOT</version>
 <name>MavenHelloWorldProject</name>
 <url>http://maven.apache.org</url>
 <dependencies>
 <dependency>
 <groupId>junit</groupId>
 <artifactId>junit</artifactId>
 <version>3.8.1</version>
 <scope>test</scope>
 </dependency>
 </dependencies>
</project>

2. Missing Artifact error

Maven artifacts are not limited to java resources. We can generate whatever resource we need like, documentation, project-site, zip-archives, native-libraries, etc.

Each maven project has a unique identifier consisting of [groupId, artifactId, version]. When a maven project requires resources of another project a dependency is configured in it’s pom.xml using the [groupId, artifactId, version] identifier. Maven then automatically resolves the dependencies when a build is triggered. The artifacts of the required projects are then loaded either from the local repository, which is a simple directory in user’s home, or from other (remote) repositories specified in the projects pom.xml.

Maven throws “Missing artifact error” when a dependency is not recognized or a dependency artifact cannot be found either in the local repository or the remote repository depending on how we have configured our project to get the dependencies (check the <url> tag in pom.xml which helps to determine where maven will refer the dependencies). It may also means that Maven is not able to download the artifacts specified in the pom.xml from the repository.

3. Resolving Missing Artifact error

Whenever we get a missing artifact error while building our Maven project, the only thing we should first try out is to check for dependencies in the pom.xml.

Things that can be checked in pom.xml:

  1. Check if the correct repository is specified in the pom.xml from which the package was downloaded originally. It might happen that the url in pom.xml is not correct and you have the required jar file in the .m2 repository.
  2. Check for the artifact version, if the version specified in the pom.xml is there in the repository from where it should be downloaded.
  3. Check if the jar is missing or not. If yes, place it manually in the .m2 repository. Sometimes the jar mentioned in the pom.xml is not downloaded and it gives error.
  4. You can also try deleting the entire .m2 repository folder and run the maven build. The jars get downloaded from scratch. It might resolve the problem as well.
  5. In eclipse, you can always try to clean the project by selecting the Project->Clean option. There are a few other options apart from Project->Clean, some of which are more along the lines of turning it off and on again.
    • Try right-clicking on the project and select Maven->Update Project.
    • Disable then re-enable dependency management (right-click Maven->Disable Maven Nature then to again convert the project to a Maven project, Right Click on the project and select Configure ->Convert To Maven Project. Please refer to the screen shots below.
    • Close the project and reopen it.

Fig 1: Disable Maven Nature

Fig 2: Convert To Maven Project

6. Check that your Maven settings are configured correctly. If you are behind a proxy you’ll need to configure the proxy settings in the global or user settings.

7. You can also try right-clicking on the project and select Maven -> Update Project and check the option for “Force Update of Snapshot/Releases”. It will clean build the project checking for dependencies. Refer to the screenshot below.

Fig 3: Force Update of Snapshots

4. Conclusion

That was an example of the “Missing Artifact error” while building a Maven project. We saw some things that can be checked in order to resolve this error.

In maven, missing artifact error in pom.xml is due to dependency download problem. The error in pom.xml “missing artifact maven” occurs when the artifact is missing in local repository and remote repository. In eclipse, missing artifact maven error shows in the programs window.

Maven is a software tool for building artifacts. The maven exception “Missing artifact” is thrown when a new dependency is added in the pom.xml file. A maven dependency is identified with group Id, artifact Id and version. If there is a problem related to these parameters, the exception “Missing artifact” will be thrown from maven pom.xml.

The code below displays an error message “Missing artifact Maven” due to dependency problem. In eclipse, along with this exception, additional errors will be shown in the programs window.

Missing artifact org.apache.commons:commons-lang3:jar:3.9.1
The container 'Maven Dependencies' references non existing library '../../.m2/repository/org/apache/commons/commons-lang3/3.9.1/commons-lang3-3.9.1.jar'
The project cannot be built until build path errors are resolved

Root Cause

The exception “missing artifact maven” can occur if a new dependency is added in the pom.xml file. Maven will check the dependence of the local repository. If this is not available, try downloading it from the source url. If the dependency is not present in either local repository or remote repository, this exception will be thrown.

There might be a different reason not to find the dependent jar files. Maven distinguishes dependency based on three factors, group id, artifact id and version.

Solution 1

Check the group id and artifact id in the dependency configuration in pom.xml. If this is a spelling error, correct it and refresh. This exception will be resolved. Make sure that the group id and artifact id are correct in the pom.xml file. The artifact like jar file is located using these parameters.

		<dependency>
			<groupId>org.apache.commons</groupId>
			<artifactId>commons-lang3</artifactId>
			<version>3.9.1</version>
		</dependency>

Solution 2

For this exception, the version is an important factor. The jars are placed in a path that is based on group id and artifact id. There are several jars available for a dependency based on their versions. For example, the jar file is going to have different versions. The jar is added to the project on the basis of the version specified in pom.xml.

First, make sure that the version number is correct. Check whether the file is available in the local repository or not. Check the version in the downloadable link on the internet.

Solution 3

Check the jar file in your local repository. The version folder is sometimes created in the local repository, but the jar file is missing. This will happen if the internet is disconnected while downloading or if something happens while downloading the jar file. In this case, there will be a folder in the local repository. But the jar file is not going to be available.

Download the jar file from the internet and place the jar file in your local repository folder.

Solution 4

This solution is not recommended at all times. If you are not concerned about your.m2 local repository, delete the local repository and refresh the maven project. Maven is going to try to download all the jars from scratch. If there is a repository related issue, this step will resolve the exception “missing artifact maven”.

Note that this will also affect other maven projects as you delete a complete.m2 local repository. It is recommended that you take backup of the entire.m2 local repository.

Solution 5

If you use eclipse as your IDE, recompile the entire project. Click “Project->clean” in the menu. This will clean up all of the target and bin folders. If there is any issue in the folder structure of the maven project, this step will resolve the issue. If any file is locked in the target or bin folders, fix it first. From the menu, click “Project->clean.”

Run the maven after cleaning the project build directory. This step is going to solve the exception.

Solution 6

In the maven project, right-click the name of the project, click “Maven->Update Project.” If any problems occur while downloading or linking the jar to the maven project, they will be resolved in this step. Maven is trying to check all the dependency jar links with the local repository and remote repository. In this step, if any issues related to linking jars will be resolved. The maven error missing artifact will also resolved.

Solution 7

If none of the above steps is working, then try these steps to resolve missing artifact maven error in pom.xml

  • try to close the project and open up the project
  • try to close the eclipse and begin the eclipse again
  • try to shut down your system and restart your system.

Click here follow the steps to fix Maven Eclipse Missing Artifact Error and related errors.

Instructions

 

To Fix (Maven Eclipse Missing Artifact Error) error you need to
follow the steps below:

Step 1:

 
Download
(Maven Eclipse Missing Artifact Error) Repair Tool
   

Step 2:

 
Click the «Scan» button
   

Step 3:

 
Click ‘Fix All‘ and you’re done!
 

Compatibility:
Windows 7, 8, Vista, XP

Download Size: 6MB
Requirements: 300 MHz Processor, 256 MB Ram, 22 MB HDD

Limitations:
This download is a free evaluation version. To unlock all features and tools, a purchase is required.

Maven Eclipse Missing Artifact Error Error Codes are caused in one way or another by misconfigured system files
in your windows operating system.

If you have Maven Eclipse Missing Artifact Error errors then we strongly recommend that you

Download (Maven Eclipse Missing Artifact Error) Repair Tool.

This article contains information that shows you how to fix
Maven Eclipse Missing Artifact Error
both
(manually) and (automatically) , In addition, this article will help you troubleshoot some common error messages related to Maven Eclipse Missing Artifact Error error code that you may receive.

Note:
This article was updated on 2023-02-03 and previously published under WIKI_Q210794

Contents

  •   1. What is Maven Eclipse Missing Artifact Error error?
  •   2. What causes Maven Eclipse Missing Artifact Error error?
  •   3. How to easily fix Maven Eclipse Missing Artifact Error errors

What is Maven Eclipse Missing Artifact Error error?

The Maven Eclipse Missing Artifact Error error is the Hexadecimal format of the error caused. This is common error code format used by windows and other windows compatible software and driver vendors.

This code is used by the vendor to identify the error caused. This Maven Eclipse Missing Artifact Error error code has a numeric error number and a technical description. In some cases the error may have more parameters in Maven Eclipse Missing Artifact Error format .This additional hexadecimal code are the address of the memory locations where the instruction(s) was loaded at the time of the error.

What causes Maven Eclipse Missing Artifact Error error?

The Maven Eclipse Missing Artifact Error error may be caused by windows system files damage. The corrupted system files entries can be a real threat to the well being of your computer.

There can be many events which may have resulted in the system files errors. An incomplete installation, an incomplete uninstall, improper deletion of applications or hardware. It can also be caused if your computer is recovered from a virus or adware/spyware
attack or by an improper shutdown of the computer. All the above actives
may result in the deletion or corruption of the entries in the windows
system files. This corrupted system file will lead to the missing and wrongly
linked information and files needed for the proper working of the
application.

How to easily fix Maven Eclipse Missing Artifact Error error?

There are two (2) ways to fix Maven Eclipse Missing Artifact Error Error:

Advanced Computer User Solution (manual update):

1) Start your computer and log on as an administrator.

2) Click the Start button then select All Programs, Accessories, System Tools, and then click System Restore.

3) In the new window, select «Restore my computer to an earlier time» option and then click Next.

4) Select the most recent system restore point from the «On this list, click a restore point» list, and then click Next.

5) Click Next on the confirmation window.

6) Restarts the computer when the restoration is finished.

Novice Computer User Solution (completely automated):

1) Download (Maven Eclipse Missing Artifact Error) repair utility.

2) Install program and click Scan button.

3) Click the Fix Errors button when scan is completed.

4) Restart your computer.

How does it work?

This tool will scan and diagnose, then repairs, your PC with patent
pending technology that fix your windows operating system registry
structure.
basic features: (repairs system freezing and rebooting issues , start-up customization , browser helper object management , program removal management , live updates , windows structure repair.)


Asked by: Prof. Demarcus Prosacco DVM

Score: 5/5
(14 votes)

Resolving Missing Artifact error. Whenever we get a missing artifact error while building our Maven project, the only thing we should first try out is to check for dependencies in the pom. xml . … xml is there in the repository from where it should be downloaded.

Can’t find artifact in nexus public?

If you are unable to find an artifact that you just know is there locally in your Nexus, the most likely causes of failure are: The proxy repository containing the artifact is not in your group repository. The download was blocked by a routing rule.

How do I resolve a missing jar in Maven repository?

1 Answer. Look in your . m2 directory (use the paths which you see in the dialog above) and check whether the files are there or whether they are really missing. If they are missing, run «mvn install» (see the «Run as…» menu) to download them.

Where does Maven store artifacts?

The local repository of Maven is a directory on the local machine, where all the project artifacts are stored. When a Maven build is executed, Maven automatically downloads all the dependency jars into the local repository. Usually, this directory is named . m2.

Why does POM XML show error?

You can usually resolve these errors by updating Maven dependencies as follows: Right-click on your top-level project (not on the pom. xml file) in the Project Explorer view. From the menu, choose Maven > Update project.

29 related questions found

How do you fix missing artifact error in POM XML?

The following solution worked for me.

  1. copy the existing pom file as a back up, and delete the dependency that’s causing this error. delete the contents of the folder which this artifact is referring to.
  2. add the deleted dependency in the pom again and add the jar files in that folder.
  3. do a Maven->update Project.

How do you solve the requested profile pom XML could not be activated because it does not exist?

Spring Maven clean error — The requested profile «pom. xml» could not be activated because it does not exist

  1. Step — 1 Right click on your project in Eclipse.
  2. Step — 2 Click Properties.
  3. Step — 3 Select Maven in the left hand side list.
  4. Step — 4 You will notice «pom.

Why does Maven download dependencies every time?

When you run a Maven build, then Maven automatically downloads all the dependency jars into the local repository. It helps to avoid references to dependencies stored on remote machine every time a project is build. Maven local repository by default get created by Maven in %USER_HOME% directory.

What is .m2 folder in Maven?

m2 are: A settings. xml file that contains global settings for all maven executions. A folder called repository that holds all of the local copies of various maven artifacts, either caches of artifacts pulled down from remote repositories, such as Maven Central, or artifacts built by your local maven builds.

Why does Maven download every time?

Maven downloads plugins and artifacts that your project depends on. Maven does in fact download artifacts from remote repositories, but it downloads the artifact once and keeps a local cache. Maven only downloads most of these dependencies because you’ve added them to your project.

How do I force MAV clean install?

Press alt+F5, window for Update Maven Project will pop up. Check — Force Update of Snapshots/releases and click OK.

How do you resolve missing artifacts?

3. Resolving Missing Artifact error

  1. Check if the correct repository is specified in the pom. …
  2. Check for the artifact version, if the version specified in the pom. …
  3. Check if the jar is missing or not. …
  4. You can also try deleting the entire .

How do I fix Maven build failure?

1:generate (default-cli) on project standalone-pom: Directory my-app already ex ists — please run from a clean directory -> [Help 1] [ERROR] [ERROR] To see the full stack trace of the errors, re-run Maven with the -e swit ch. [ERROR] Re-run Maven using the -X switch to enable full debug logging.

How do I set Nexus repository in settings XML?

xml in order to read and publish artifacts to your Nexus server.

  1. Step 1: Download. …
  2. Step 2: Install. …
  3. Step 3: Configure security. …
  4. Step 4: Set SMTP server. …
  5. Step 5: Change Base Url. …
  6. Step 6: Add a task to periodically remove old snapshots. …
  7. Step 7: Using Nexus: reading and publishing artifacts.

How do I manually create a m2 folder?

To generate the folder you have to run any maven command e.g. mvn clean, mvn install etc.

prefix on Windows, you can simply do this on the command line.

  1. Go to Start->Run.
  2. Type cmd and press Enter.
  3. At the command prompt type md c:UsersJonathan. m2 (or equivalent for your ${user. home} value).

What is mvn clean install command?

mvn clean install is the command to do just that. You are calling the mvn executable, which means you need Maven installed on your machine. … You are using the clean command, which will delete all previously compiled Java .

How do I find my Maven path?

Maven in PATH

You run Maven by invoking a command-line tool: mvn. cmd from the bin directory of the Maven. To do this conveniently, ${maven. home}bin must be in your PATH, just like the Java SDK commands.

How do I download Maven dependencies?

Via the Maven index, you can search for dependencies, select them and add them to your pom file. To download the index, select Windows > Preferences > Maven and enable the Download repository index updates on startup option. After changing this setting, restart Eclipse. This triggers the download of the Maven index.

What are the three builds in the Maven life cycle?

There are three built-in build lifecycles: default, clean and site. The default lifecycle handles your project deployment, the clean lifecycle handles project cleaning, while the site lifecycle handles the creation of your project’s web site.

What is POM XML file?

A Project Object Model or POM is the fundamental unit of work in Maven. It is an XML file that contains information about the project and configuration details used by Maven to build the project. … Other information such as the project version, description, developers, mailing lists and such can also be specified.

Could not be activated because it does not exist maven?

The cause may be that you have had a in you pom. xml, and used it in the build. When you remove it from pom. xml — it remains in the run configuration, even if it does not show up in the project explorer’s Maven context menu (Maven > Select Maven Profiles …)

What does missing artifact mean?

The maven exception “Missing artifact” is thrown when a new dependency is added in the pom.xml file. A maven dependency is identified with group Id, artifact Id and version. If there is a problem related to these parameters, the exception “Missing artifact” will be thrown from maven pom.

How do I fix POM XML error in eclipse?

To be more sure:- Right click on your Maven project in Eclipse and select Maven -> Update Project … Make sure that, you do not have any proxy related problems when updating the project again. Additionally,right click on the pom. xml file in the ‘project explorer’ > click on ‘validate’.

What is artifact in Maven project?

Artifact: An artifact is something that is either produced or used by a project. Examples of artifacts produced by Maven for a project include: JARs, source and binary distributions, WARs. … Dependency: A typical Java project relies on libraries to build and/or run. Those are called “dependencies” inside Maven.

How do you resolve build failure?

Reduce build failures and increase build reliability

  1. Pull in help for an unexpectedly failing test.
  2. See all locally failing tests across all projects.
  3. Determine if changed dynamic dependencies broke the build.
  4. Investigate why your project does not compile on your colleague’s machine.

A friend has passed me a Maven project that I’m trying to run locally in my computer. All that I have done in Eclipse, I selected:

File -> Import -> Existing Maven Projects

After that, the project showed me 4 errors in my pom.xml (Missing artifact..):

I tried removing the content of .m2 folder and then in Eclipse I clicked on my project and chose «Run as» -> «Maven clean» and then «Run as» -> «Maven install». But I still have the same errors. I’m new with Spring so I dont know what else to do.

EDIT:

When I try to do: run as/ maven install, this is what my console says:

SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder".
SLF4J: Defaulting to no-operation (NOP) logger implementation
SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details.
[INFO] Scanning for projects...
[INFO]                                                                         
[INFO] ------------------------------------------------------------------------
[INFO] Building DataLayer 0.0.1-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[WARNING] The POM for javax.persistence:javax.persistence:jar:1.0.0 is missing, no     dependency information available
[WARNING] The POM for hibernate-core:hibernate-core:jar:4.2.1.Final is missing, no     dependency information available
[WARNING] The POM for hibernate-commons-annotations:hibernate-commons-annotations:jar:4.0.1.Final is missing, no dependency information available
[WARNING] The POM for jboss-logging:jboss-logging:jar:3.1.0.CR2 is missing, no dependency information available
[WARNING] The POM for jta:jta:jar:1.1 is missing, no dependency information available
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1.065s
[INFO] Finished at: Wed Aug 07 11:41:45 VET 2013
[INFO] Final Memory: 4M/90M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal on project DataLayer: Could not resolve dependencies for     project SocialManager:DataLayer:jar:0.0.1-SNAPSHOT: The following artifacts could not be resolved: javax.persistence:javax.persistence:jar:1.0.0, hibernate-core:hibernate-core:jar:4.2.1.Final, hibernate-commons-annotations:hibernate-commons-annotations:jar:4.0.1.Final, jboss-logging:jboss-logging:jar:3.1.0.CR2, jta:jta:jar:1.1: Failure to find javax.persistence:javax.persistence:jar:1.0.0 in http://repository.jboss.org/nexus/content/groups/public/ was cached in the local repository, resolution will not be reattempted until the update interval of JBoss repository has elapsed or updates are forced -> [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.

EDIT2: This is my complete pom.xml: https://dl.dropboxusercontent.com/u/31349296/pom.xml It looks pretty awful when I try to paste the code here.

Понравилась статья? Поделить с друзьями:
  • Mismatch image and device error
  • Mismatch error sans theme скачать
  • Mirrors edge ошибка при подключении к серверу лицензий на пиратке
  • Mirrors edge ошибка при запуске приложения 0xc0000906
  • Mirrors edge ошибка application load error 5 0000065434