Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Eclipse not wanting to build due to circular dependencies

 
Dieter Quickfend
Bartender
Posts: 543
4
Java Netbeans IDE Redhat
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
So, I've got this problem. I am a NetBeans guy, practicing Eclipse now because I should teach it to my students as it's used more on the job. Now, as I was setting up an EJB Project from a coursebook, Eclipse started giving me errors. The big ol' exclamation mark above the EJBProj and EJBClient project folders. The problems view said they weren't being built because of circular dependencies in the build path. But it was a beginner project and they hardly had any dependencies, let alone circular ones. They both have a dependency on JBoss and JRE, that's basically it.

Anyway, I decided to go to Windows/Preferences/Java/Compiler and set circular dependencies to warning instead of error, which made the project run flawlessly, showing that there really wasn't a problem.

This is not good though. I understand that my knowledge of Eclipse is not so broad yet, but in order to solve the issues of a classroom full of students, I need to understand this type of problem and where it comes from.

Anyone got an idea?



Dieter
 
David Newton
Author
Rancher
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It's unlikely there wasn't a circular dependency, but without knowing more, it's impossible to say.
 
Dieter Quickfend
Bartender
Posts: 543
4
Java Netbeans IDE Redhat
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hmm. I was sure I'd posted a reply earlier.... Anyhow, I found the problem. I followed the Eclipse wizard to create the EAR with the EJB jar in it, and checked the option to create a Client as well... Apparently, the EAR contained the client and the EJB jar, and the client also had a dependency on the EJB jar so I could address the EJB that was on the server. I removed the client from the EAR and it worked, no warnings, no errors. Why did the wizard add the client to the EAR? Is it supposed to do that?
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic