|Dependency management with Nexus references [message #656067]
||Wed, 23 February 2011 20:15
Registered: February 2011
Hi, I am having some issues with dependency management between multiple Maven modules and a Nexus repository. I have found that searching for references in Eclipse only looks in the modules that are currently open. This means that refactoring will not work unless I open all affected modules.|
Is there any way to tell Eclipse to search for references within a Nexus repository (that is if the module isn't already open in Eclipse)?
Alternatively (and more favorably), is there a way to have Eclipse search through all of the unopened modules? Also, if there is a refactor being made could it open the Maven module up and do the change?
|Re: Dependency management with Nexus references [message #656916 is a reply to message #656656]
||Mon, 28 February 2011 18:47
| Carlos Sanchez
Registered: July 2009
On 2/27/11 4:07 PM, keni wrote:|
> Would you be able to expand on "sources in the local maven repo are
> attached to the jars in the classpath"?
if "download sources" is checked in the Maven Preferences under Eclipse,
or you right click on a project -> Maven 2 -> Fetch source jars the
sources are downloaded from the Maven repo (if available) and attached
to the jars in the classpath
You can see it in Project preferences - Java Build Path - Libraries -
Maven Classpath Container
> I can see how the 3rd party dependencies are added to the Eclipse
> classpath using the MAVEN2_CLASSPATH_CONTAINER, but this does not appear
> to be adding in the jars for my dependent modules.
Dependent modules opened in the workspace are added as project dependencies.
Dependent modules not opened in the workspace are added as jar
dependencies in the Maven Classpath Container
> Also, how would Maven handle a refactor operation if the modules that
> depend on a class are not opening in the workspace? Would you simply do
> the change and than wait for the build result??
It's not Maven who does the refactoring, it's Eclipse. Eclipse won't
touch any project that is not opened, so any dependency or anything that
depends on the project you refactor won't be changed
Powered by FUDForum
. Page generated in 0.01766 seconds