Maven dependencies not allowed in Eclipse

I am developing my own Oracle authentication plugin (OAM 11g) using maven dependencies. I followed all the steps listed in the Oracle documentation to add maven dependencies:

1) Created an account in OTN and accepted the license 2) Created my settings file and POM file and added the following:

<server> <id>maven.oracle.com</id> <username> myemail@gmail.com </username> <password>*******</password> <configuration> <basicAuthScope> <host>ANY</host> <port>ANY</port> <realm>OAM 11g</realm> </basicAuthScope> <httpConfiguration> <all> <params> <property> <name>http.protocol.allow-circular-redirects</name> <value>%b,true</value> </property> </params> </all> </httpConfiguration> </configuration> </server> 

After completing these steps, I still get the error message "Import oracle.security error could not be resolved" in my Java class, which means dependencies and are not resolved in my program. I would appreciate if anyone could help me understand this problem. thanks

0
source share
2 answers

I do not think this problem is related to oracle security. Banks associated with the oracle are usually not published in the central part due to licensing restrictions. You need

  • Upload banners manually to your company or to an artificial company.
  • OR save them with your project and use the system dependency mechanism.

Explanation of point 2:

  • Maintain the jar folder in your project and save the jar files.
  • In your dependency fragment in pom,
 <dependencies> <dependency> <groupId>oracle.security</groupId> <artifactId>oracle-api</artifactId> <version>2.0</version> <scope>system</scope> <systemPath>${project.basedir}/jars/oracle-api.jar</systemPath> </dependency> </dependencies> 

Repeat above for other cans.

This will eliminate the The import oracle.security cannot be resolved exception.

0
source

You need to add the following repository definition to your pom.xml.

You get more information here by creating multiple repositories.

 <repositories> <repository> <id>maven.oracle.com</id> <releases> <enabled>true</enabled> </releases> <snapshots> <enabled>false</enabled> </snapshots> <url>https://maven.oracle.com</url> <layout>default</layout> </repository> </repositories> <pluginRepositories> <pluginRepository> <id>maven.oracle.com</id> <url>https://maven.oracle.com</url> </pluginRepository> </pluginRepositories> 
0
source

Source: https://habr.com/ru/post/1268521/


All Articles