Not able to build existing Maven project in Eclipse | Community
Skip to main content
New Participant
February 5, 2016
Solved

Not able to build existing Maven project in Eclipse

  • February 5, 2016
  • 11 replies
  • 7148 views

Dear Team,

First time I am building my maven project in eclipse for CQ.

I have my existing maven project download from SVN.

I just imported my existing maven project in eclipse.

Already I have setup my settings.xml file in c/users/username/.m2 folder as below.

<profile>
  <id>common</id>
  <properties> 
    <crx.username>admin</crx.username>
    <crx.password>admin</crx.password>
  </properties> 
</profile> 

<profile>
  <id>localAuthor</id> 
  <properties> 
    <instance.url>http://localhost:4502</instance.url> 
  </properties>
</profile>

<profile>
  <id>localPublish</id> 
  <properties> 
    <instance.url>http://localhost:4503</instance.url> 
  </properties>
</profile>

<profile>
    <id>localSonar</id>
    <properties>
        <sonar.host.url>http://localhost:9000</sonar.host.url>
        <sonar.jdbc.url>jdbc:h2:tcp://localhost:9092/sonar</sonar.jdbc.url>
        <sonar.jdbc.username>sonar</sonar.jdbc.username>
        <sonar.jdbc.password>sonar</sonar.jdbc.password>
        <sonar.jdbc.driver>org.h2.Driver</sonar.jdbc.driver>
    </properties>
</profile>


But after run my pom.xml , I am getting below error.

[INFO] Scanning for projects...
[INFO] 
[INFO] Using the builder org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder with a thread count of 1
[INFO]                                                                         
[INFO] ------------------------------------------------------------------------
[INFO] Building sunitaproject - flextemplate portal webapp module 1.16.1
[INFO] ------------------------------------------------------------------------
[WARNING] The POM for com.sunitaproject.dfac.sunitaprojectfoundation:sunitaprojectfoundation-webapp:jar:1.31.4 is missing, no dependency information available
[WARNING] The POM for com.cognifide.cq:framework-54-api:jar:2.3.0 is missing, no dependency information available
[WARNING] The POM for com.cognifide.cq:framework-54-core:jar:2.3.0 is missing, no dependency information available
[WARNING] The POM for com.cognifide.cq:framework-54-taglib:jar:2.3.0 is missing, no dependency information available
[WARNING] The POM for com.cognifide.cq:sling-dynamic-include:jar:0.6.2 is missing, no dependency information available
[WARNING] The POM for com.sunitaproject.dfac:rum-bundle:jar:1.22.3 is missing, no dependency information available
[WARNING] The POM for com.cognifide.sunitaproject:framework-extra-taglib:jar:0.1.14 is missing, no dependency information available
[WARNING] The POM for com.cognifide.cq.extra:framework-extra-core:jar:0.1.7 is missing, no dependency information available
[WARNING] The POM for rome:rome:jar:1.0-osgi-fixed is missing, no dependency information available
[WARNING] The POM for com.google.guava:guava:jar:15 is missing, no dependency information available
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 4.316 s
[INFO] Finished at: 2016-02-05T08:07:07-05:00
[INFO] Final Memory: 12M/220M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal on project flextemplate-webapp: Could not resolve dependencies for project com.sunitaproject.dfac.flextemplate:flextemplate-webapp:bundle:1.16.1: The following artifacts could not be resolved: com.sunitaproject.dfac.sunitaprojectfoundation:sunitaprojectfoundation-webapp:jar:1.31.4, com.cognifide.cq:framework-54-api:jar:2.3.0, com.cognifide.cq:framework-54-core:jar:2.3.0, com.cognifide.cq:framework-54-taglib:jar:2.3.0, com.cognifide.cq:sling-dynamic-include:jar:0.6.2, com.sunitaproject.dfac:rum-bundle:jar:1.22.3, com.cognifide.sunitaproject:framework-extra-taglib:jar:0.1.14, com.cognifide.cq.extra:framework-extra-core:jar:0.1.7, rome:rome:jar:1.0-osgi-fixed, com.google.guava:guava:jar:15: Failure to find com.sunitaproject.dfac.sunitaprojectfoundation:sunitaprojectfoundation-webapp:jar:1.31.4 in http://repo.adobe.com/nexus/content/groups/public/ was cached in the local repository, resolution will not be reattempted until the update interval of adobe 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.
[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/DependencyResolutionException

NOTE: My localhost:4502 is currently running.

Anything I need to setup in setting.xml file?

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by ogill

Sunita Choudhury wrote...

Yes I did all the steps whatever it is mentioned in https://helpx.adobe.com/experience-manager/using/first-osgi.html.

Still my dependency jars file are not automatically created in .m2 repo.

Anybody can help me on this. Thanks

 

The dependencies you are searching for are not available in the Adobe repo as they are Cognifide artifacts, so you would need to request help from Cognifide.

You need to search for the dependencies and include the correct version. For example I searched for:

        <dependency>
            <groupId>com.cognifide.cq</groupId>
            <artifactId>sling-dynamic-include</artifactId>
            <version>0.6.2</version>
        </dependency>

and could only find the following in the central maven repository: http://mvnrepository.com/artifact/com.cognifide.cq/sling-dynamic-include which starts at version 1.0. Is the code you are trying to import from an old code repository?

Regards,

Opkar

11 replies

edubey
New Participant
February 5, 2016

Make sure that dependencies for these files are added in your project pom.xml and are jar files are available in your local maven repository

[WARNING] The POM for com.sunitaproject.dfac.sunitaprojectfoundation:sunitaprojectfoundation-webapp:jar:1.31.4 is missing, no dependency information available
[WARNING] The POM for com.cognifide.cq:framework-54-api:jar:2.3.0 is missing, no dependency information available
[WARNING] The POM for com.cognifide.cq:framework-54-core:jar:2.3.0 is missing, no dependency information available
[WARNING] The POM for com.cognifide.cq:framework-54-taglib:jar:2.3.0 is missing, no dependency information available
[WARNING] The POM for com.cognifide.cq:sling-dynamic-include:jar:0.6.2 is missing, no dependency information available
[WARNING] The POM for com.sunitaproject.dfac:rum-bundle:jar:1.22.3 is missing, no dependency information available
[WARNING] The POM for com.cognifide.sunitaproject:framework-extra-taglib:jar:0.1.14 is missing, no dependency information available
[WARNING] The POM for com.cognifide.cq.extra:framework-extra-core:jar:0.1.7 is missing, no dependency information available
[WARNING] The POM for rome:rome:jar:1.0-osgi-fixed is missing, no dependency information available
[WARNING] The POM for com.google.guava:guava:jar:15 is missing, no dependency information available