Forum Stats

  • 3,839,047 Users
  • 2,262,441 Discussions
  • 7,900,839 Comments

Discussions

Oracle ADF,Jdev 12.2.1.4.0, Maven 3.8.6, BUILD FAILURE

M Yaa Ser
M Yaa Ser Member Posts: 64 Blue Ribbon
edited Jul 25, 2022 9:03AM in JDeveloper and ADF

Hello Seniors,

I am all new using Maven in my ADF application. I need little help and guidance.

1-Also please guide as I have chunks application and using all of them as JAR library in main application so all application should have pom.xml file?

2-is there any specific setting in pom.xml file for build and creating EAR process? please share link to follow any tutorial.

I set MAVEN_HOME and used below tutorial for creating EAR file

https://www.youtube.com/watch?v=ht8JgEAmrI8.

I am just trying to run pom.xml file as run maven clean so I am getting below error

[INFO] Scanning for projects...

[INFO]                                     

[INFO] ------------------------------------------------------------------------

[INFO] Building PlzServiceModel 1.0-SNAPSHOT

[INFO] ------------------------------------------------------------------------

Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-clean-plugin/2.5/maven-clean-plugin-2.5.pom


[INFO] ------------------------------------------------------------------------

[INFO] BUILD FAILURE

[INFO] ------------------------------------------------------------------------

[INFO] Total time: 1.299 s

[INFO] Finished at: 2022-07-25T10:37:21+02:00

[INFO] Final Memory: 10M/238M

[INFO] ------------------------------------------------------------------------

[ERROR] Plugin org.apache.maven.plugins:maven-clean-plugin:2.5 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-clean-plugin:jar:2.5: Could not transfer artifact org.apache.maven.plugins:maven-clean-plugin:pom:2.5 from/to central (https://repo.maven.apache.org/maven2): sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target -> [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

Process exited with exit code 1.

Answers

  • Timo Hahn
    Timo Hahn Senior Principal Technical Consultant - Oracle ACE Director Member, Moderator Posts: 38,588 Red Diamond

    You can start by looking at this ADF Insider video about JDEV and Maven https://www.youtube.com/watch?v=ht8JgEAmrI8

    The documentation like https://docs.oracle.com/en/middleware/developer-tools/jdeveloper/12.2.1.4/user-guide/developing-applications-oracle-jdeveloper.pdf guides you through the process.

    Or you can look at by blog here https://blog.virtual7.de/jdeveloper-12-2-1-4-maven-build-and-junit-tests-part-1/ where I give some essential info on how to set up the projects.

    Timo

  • dvohra21
    dvohra21 Member Posts: 14,618 Gold Crown

    Similar to an earlier question by a different user. Rerun with -e as suggested:

    To see the full stack trace of the errors, re-run Maven with the -e switch.

  • M Yaa Ser
    M Yaa Ser Member Posts: 64 Blue Ribbon

    Thanks For your response Timo,

    Should I install local repository in my system to install or to get access https://repo.maven.apache.org/maven2 to install dependent libraries and plugins? if yes so how can I do it. Because every timeI get a BUILD FAILURE to download plugins or libraries.

    You can see in below log.


    [INFO] Scanning for projects...

    [INFO]                                     

    [INFO] ------------------------------------------------------------------------

    [INFO] Building PlzServiceModel 1.0-SNAPSHOT

    [INFO] ------------------------------------------------------------------------

    Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-resources-plugin/2.6/maven-resources-plugin-2.6.pom


    [INFO] ------------------------------------------------------------------------

    [INFO] BUILD FAILURE

    [INFO] ------------------------------------------------------------------------

    [INFO] Total time: 0.995 s

    [INFO] Finished at: 2022-07-26T11:59:44+02:00

    [INFO] Final Memory: 12M/300M

    [INFO] ------------------------------------------------------------------------

    [ERROR] Plugin org.apache.maven.plugins:maven-resources-plugin:2.6 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-resources-plugin:jar:2.6: Could not transfer artifact org.apache.maven.plugins:maven-resources-plugin:pom:2.6 from/to central (https://repo.maven.apache.org/maven2): sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target -> [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

    Process exited with exit code 1.

  • Timo Hahn
    Timo Hahn Senior Principal Technical Consultant - Oracle ACE Director Member, Moderator Posts: 38,588 Red Diamond

    I would install a local repository as it's more reliable.

    Your maven configuration has a problem. You should read and work through the documents I posted already.


    Timo

  • M Yaa Ser
    M Yaa Ser Member Posts: 64 Blue Ribbon

    Dear Timo,

    I followed the given documents so it's start compiling but at the end I get below error.


    [INFO] Scanning for projects...

    [INFO]                                     

    [INFO] ------------------------------------------------------------------------

    [INFO] Building PlzServiceModel 1.0-SNAPSHOT

    [INFO] ------------------------------------------------------------------------

    [WARNING] The POM for com.oracle.adf.library:ADF-Library:pom:12.2.1-4-0 is missing, no dependency information available

    [WARNING] The POM for com.oracle.adf.library:Apache-Commons-IO:pom:12.2.1-4-0 is missing, no dependency information available

    [INFO] ------------------------------------------------------------------------

    [INFO] BUILD FAILURE

    [INFO] ------------------------------------------------------------------------

    [INFO] Total time: 0.392 s

    [INFO] Finished at: 2022-08-08T14:57:19+02:00

    [INFO] Final Memory: 7M/238M

    [INFO] ------------------------------------------------------------------------

    [ERROR] Failed to execute goal on project PlzServiceModel: Could not resolve dependencies for project dguv.plzservice:PlzServiceModel:war:1.0-SNAPSHOT: The following artifacts could not be resolved: com.oracle.adf.library:ADF-Library:pom:12.2.1-4-0, com.oracle.adf.library:Apache-Commons-IO:pom:12.2.1-4-0: Failure to find com.oracle.adf.library:ADF-Library:pom:12.2.1-4-0 in http://nexus.dguv.de/repository/maven-group/ was cached in the local repository, resolution will not be reattempted until the update interval of nexus.dguv.de 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

    Process exited with exit code 1.

  • Timo Hahn
    Timo Hahn Senior Principal Technical Consultant - Oracle ACE Director Member, Moderator Posts: 38,588 Red Diamond

    The error is stating that a needed library or POM is missing.

    Have you tried to find the missing library or POM in your nexus by browsing the available artifacts?

    Timo

  • dvohra21
    dvohra21 Member Posts: 14,618 Gold Crown

    The following artifacts could not be resolved: com.oracle.adf.library:ADF-Library:pom:12.2.1-4-0, com.oracle.adf.library:Apache-Commons-IO:pom:12.2.1-4-0

    The message means that the following dependencies cannot be resolved:

    <dependency>
       <groupId>com.oracle.adf.library</groupId>
       <artifactId>ADF-Library</artifactId>
       <version>12.2.1-4-0</version>
       <type>pom</type>
    </dependency>
    
    <dependency>
       <groupId>com.oracle.adf.library</groupId>
       <artifactId>Apache-Commons-IO</artifactId>
       <version>12.2.1-4-0</version>
       <type>pom</type>
    </dependency>
    
  • M Yaa Ser
    M Yaa Ser Member Posts: 64 Blue Ribbon

    @dvohra21 Yes Sir, why can't it resolve auto as other libraries downloading auto. Do you know any reason or solution?

    @Timo Hahn Yes Sir, i can find those, and I am using nexus because of proxy.