0

I am not able to understand why maven is not picking up the dependency.

It is downloading that dependency in the repository as below,

enter image description here

Other source are getting compiled only related to this class not compiling, that is depend on

<dependency>
    <groupId>com.maxmind.geoip</groupId>
    <artifactId>geoip-api</artifactId>
    <version>1.3.1</version>
</dependency> 

Maven is not picking up neither in eclipse and nor in command line maven build.

Can any one help me what I am missing here.? Thanks in advance, for help and information.

enter image description here

[INFO] koarb - Services .................................. SUCCESS [  7.093 s]
[INFO] gtz koarb 3.0 - webapp ............................ FAILURE [ 33.759 s]
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 01:30 min
[INFO] Finished at: 2016-07-01T09:40:01+07:00
[INFO] Final Memory: 212M/868M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:2.3:compile (default-compile) on project com.gtz.koarb.web: Compilation failure:
Compilation failure:
[ERROR] src\main\java\com\gtz\koarb\web\controllers\countryresolver\IPResolverServiceImpl.java:[41,3] error
: cannot find symbol
[ERROR]
[ERROR] src\main\java\com\gtz\koarb\web\controllers\countryresolver\IPResolverServiceImpl.java:[41,30] erro
r: cannot find symbol
[ERROR]
[ERROR] src\main\java\com\gtz\koarb\web\controllers\countryresolver\IPResolverServiceImpl.java:[41,81] erro
r: cannot find symbol
[ERROR]
[ERROR] src\main\java\com\gtz\koarb\web\controllers\countryresolver\IPResolverServiceImpl.java:[42,3] error
: cannot find symbol
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e swit
Harshil Sharma
  • 2,016
  • 1
  • 29
  • 54
Gautam
  • 3,707
  • 5
  • 36
  • 57
  • check if the dependency is available in maven dependency package in the package explorer of eclipse. – Prabhat Jul 01 '16 at 03:28
  • Yes its not present in dependency package in package explore of Eclipse. When i delete it manually from .m2 repository its getting downloaded when i run maven from command line. Even though it not using that as reference class path during compilation. – Gautam Jul 01 '16 at 03:35
  • if it gets downloaded it should be available in the maven dependency package. just try to remove the dependency from .m2 repository and from the pom file, refresh the project and try again. – Prabhat Jul 01 '16 at 03:47
  • 1
    Try update the project with "force update releases/snapshots" options on. – glee8e Jul 01 '16 at 03:54
  • force update releases/snapshots, can you tell me how to do that. – Gautam Jul 01 '16 at 03:57
  • 1
    In Eclipse, right click your project. Maven -> Update Project. Check the checkbox for Force update of Snapshots/Releases. Click Ok. – Aditya Gupta Jul 01 '16 at 04:20
  • Did you try mvn eclipse:eclipse ? – Bhargav Kumar R Jul 01 '16 at 05:20
  • Can you show the full pom file? – khmarbaise Jul 01 '16 at 07:52
  • In my dependency related to geoip-api was in the last of dependencies list now I change and put it in first. Suddenly it start working in command line outside of eclipse. Though project is building successfully in command line in windows and Linux system but it still falling and shows problem in eclipse. – Gautam Jul 03 '16 at 09:11

0 Answers0