1 Reply Latest reply on Apr 6, 2009 9:18 AM by joe.luo

    cannot install from local maven repo

    davisond

      my local maven repo is not ~/.m2/repository but FUSE seems to be hardwired to look here for local artifacts.  This error is shown in the console attempting to install a bundle;

      servicemix> osgi install mvn:org.davisononline/file-poller/1.0-SNAPSHOT

      java.lang.RuntimeException: URL mvn:org.davisononline/file-poller/1.0-SNAPSHOT could not be resolved. (enable TRACE logging for details)

       

       

      In the TRACE log, the following entry can be seen;

      18:51:59,830 | TRACE | Thread-33        | Connection                       | .pax.url.mvn.internal.Connection  150 |   Version from URL file:/home/darren/.m2/repository/org/davisononline/file-poller/1.0-SNAPSHOT/file-poller-1.0-SNAPSHOT.jar

       

       

      My local maven repo is defined as follows;

      darren@hepburn ~ $ grep localRepository ~/.m2/settings.xml

         

       

       

      Vanilla servicemix4 does not seem to have this problem - it installs local artifacts correctly out of the box. 

       

      Anyone know of a reason/fix for this?

       

      Cheers,

       

      Edited by: davisond on Apr 5, 2009 6:09 PM: some way to escape text in here would be a good idea

        • 1. Re: cannot install from local maven repo
          joe.luo

          To solve this problem, you will need to change default configuration for org.ops4j.pax.url.mvn.localRepository from org.ops4j.pax.url.mvn.cfg file.

           

          Try to change the file with following configuration:

          org.ops4j.pax.url.mvn.settings=${user.home}/.m2/settings.xml

          #org.ops4j.pax.url.mvn.localRepository=file:${servicemix.home}/system@snapshots