• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Bear Bibeault
  • Liutauras Vilda
Sheriffs:
  • Jeanne Boyarsky
  • Tim Cooke
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Jj Roberts
  • Carey Brown
Bartenders:
  • salvin francis
  • Frits Walraven
  • Piet Souris

Can't resolve dependencies

 
Rancher
Posts: 1170
18
IntelliJ IDE Hibernate Firefox Browser MySQL Database Spring Tomcat Server Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hey...

I'm trying to import a project I started on my personal laptop to my worklaptop, where I just installed intelij.
For some reasson maven c an't resolve my dependencies and jave version keeps refering to 1.5 while I'm using the 1.8sdk and language level.
I tried to adjust my settings, I checked compiler.xml in the idea folder and tried to do a clean install which failed.
I even tried to start a whole new project.
Any sugestions on how to fix this? On my personal laptop everything still works great...

Pom.xml:



Error when running as an application:


Error when trying clean install from comandline:


Especially note line 30 from the last codeblock, what does that even meen, I would think it might be a firewall problem, but even when I manually download the jars and put them on my classpath myself, it still dosnt work.
 
Saloon Keeper
Posts: 12622
273
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
It seems that its syncing a copy of Spring Boot to the Maven repository at https://www.e-contract.be/maven2/, but it's not successful and then it can't find that POM when you use it in your project.

Can you verify that org.springframework.boot:spring-boot-starter-parent is in the custom repository? Why are you using the custom repository in the first place?

If the project can resolve the parent POM and you keep having the Java version issue, then instead of <java.version>, use the following:
 
Daniel Demesmaecker
Rancher
Posts: 1170
18
IntelliJ IDE Hibernate Firefox Browser MySQL Database Spring Tomcat Server Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Not to sound like a noob, but what do you meen by the custom repo? Thats the one given to me by spring initializr. Would it help if I would import the setting from my personal intelij to the one on my workcomputer?
If I use the maven compiler source, instead of version I get this:
 
Daniel Demesmaecker
Rancher
Posts: 1170
18
IntelliJ IDE Hibernate Firefox Browser MySQL Database Spring Tomcat Server Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
However, now I'm on my homenetwork the dependencies are resolved... Could It have bin a firewall issue as I previous stated and if so... Why wasn't I able to put it manually on the classpath?
 
Sheriff
Posts: 7111
184
Eclipse IDE Postgres Database VI Editor Chrome Java Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Daniel Demesmaecker wrote:Not to sound like a noob, but what do you meen by the custom repo?


I believe that Stephan was speaking of this:
Meaning a repository that's not the standard one that Maven uses.
 
Knute Snortum
Sheriff
Posts: 7111
184
Eclipse IDE Postgres Database VI Editor Chrome Java Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Daniel Demesmaecker wrote:However, now I'm on my homenetwork the dependencies are resolved... Could It have bin a firewall issue as I previous stated and if so... Why wasn't I able to put it manually on the classpath?


How were you manually adding something to a classpath?  If you're executing a Maven project outside of Maven, the only classpath you should need would look like this:

   <home directory>\.m2\repository
 
Daniel Demesmaecker
Rancher
Posts: 1170
18
IntelliJ IDE Hibernate Firefox Browser MySQL Database Spring Tomcat Server Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The dependency is actualy for the belgian e-id...
And to manually add something to the classpath I download the jar file from the maven repository and then go to projectstructure and add it to the libary
 
Daniel Demesmaecker
Rancher
Posts: 1170
18
IntelliJ IDE Hibernate Firefox Browser MySQL Database Spring Tomcat Server Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
And yes in mormal cases my dependencies get downloaded automaticly and are stored in the .m2 folder
 
Knute Snortum
Sheriff
Posts: 7111
184
Eclipse IDE Postgres Database VI Editor Chrome Java Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Daniel Demesmaecker wrote:The dependency is actualy for the belgian e-id...
And to manually add something to the classpath I download the jar file from the maven repository and then go to projectstructure and add it to the libary


What reason do you have to do this?  If it can be found by the Maven repository, why manually download it?  Also, I don't see anything in your POM file that looks like a repository pointing to a local directory in your project folder.
 
Knute Snortum
Sheriff
Posts: 7111
184
Eclipse IDE Postgres Database VI Editor Chrome Java Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Daniel Demesmaecker wrote:And yes in mormal cases my dependencies get downloaded automaticly and are stored in the .m2 folder


What are the reasons for a "non-normal" case?
 
Daniel Demesmaecker
Rancher
Posts: 1170
18
IntelliJ IDE Hibernate Firefox Browser MySQL Database Spring Tomcat Server Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Sometimes I don't know why, my dependencies don't get downloaded automaticly or there get downoaded but aren't recognized, especially for the mysql-connector is that often the case and then I have to add them manually like described above...
 
Knute Snortum
Sheriff
Posts: 7111
184
Eclipse IDE Postgres Database VI Editor Chrome Java Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I think that's because you need to add a repository for MySQL, like this:

 
Or we might never have existed at all. Freaky. So we should cherish everything. Even this tiny ad:
the value of filler advertising in 2020
https://coderanch.com/t/730886/filler-advertising
reply
    Bookmark Topic Watch Topic
  • New Topic