We are using Maven (with Tycho) and Nexus to build our Eclipse plugins. While we are continuously digging deeper into it, we are still learning how to use Maven with Nexus best. Our plugins will have to run on Eclipse 3.6 or better, so we defined bundle requirements pointing to Eclipse 3.6. We are running our own Nexus which should act as a mirror to the public repository, but there seem to be only the latest versions available on repo.eclipse.org, not the older 3.6 we need, as we keep getting
[ERROR] Cannot resolve project dependencies:
[ERROR] Software being installed: our.own.plugin 3.0.0.qualifier
[ERROR] Missing requirement: our.own.plugin 3.0.0.qualifier requires 'bundle org.eclipse.core.runtime 3.6.0' but it could not be found
Is there a public Nexus repository available for older versions? If not, where can we get the 3.6 artifacts to upload them on our local Nexus?
After some more investigation, I find that after I added a proxy from download.eclipse.org/eclipse/updates/3.6/ as remote repository to Nexus, the build keeps saying
[INFO] Fetching p2.index from http://192.168.205.205:8081/nexus/content/groups/public-p2/ (0B of 134B at 0B/s)
[INFO] Fetching p2.index from http://192.168.205.205:8081/nexus/content/groups/public-p2/ (134B of 134B at 0B/s)
[INFO] Loading repository 'http://192.168.205.205:8081/nexus/content/repositories/eclipse-4.4' from mirror 'nexus-p2' at '192.168.205.205:8081/nexus/content/groups/public-p2/'
and finally fails after a while with
Exception in thread "main" java.lang.StackOverflowError
at org.eclipse.equinox.internal.p2.transport.ecf.RepositoryTransport.download(RepositoryTransport.java:111)
at org.eclipse.equinox.internal.p2.transport.ecf.RepositoryTransport.download(RepositoryTransport.java:156)
at org.eclipse.equinox.internal.p2.repository.helpers.AbstractRepositoryManager.loadIndexFile(AbstractRepositoryManager.java:735)
at org.eclipse.equinox.internal.p2.repository.helpers.AbstractRepositoryManager.loadRepository(AbstractRepositoryManager.java:657)
at org.eclipse.equinox.internal.p2.metadata.repository.MetadataRepositoryManager.loadRepository(MetadataRepositoryManager.java:96)
at org.eclipse.tycho.p2.remote.RemoteMetadataRepositoryManager.loadRepository(RemoteMetadataRepositoryManager.java:59)
at org.eclipse.tycho.p2.remote.RemoteMetadataRepositoryManager.loadRepository(RemoteMetadataRepositoryManager.java:52)
at
...
What is the problem?
I noticed that the remote Eclipse 3.6 repository does not have a p2.index file, so I tried Eclipse 4.4, but I receive the same result.
I use Nexus as a mirror for all repositories by adding the following configuration to .m2/settings.xml:
<mirror>
<id>nexus</id>
<mirrorOf>*</mirrorOf>
<url>http://192.168.205.205:8081/nexus/content/groups/public/</url>
</mirror>
<mirror>
<id>nexus-p2</id>
<mirrorOf>*</mirrorOf>
<mirrorOfLayouts>p2</mirrorOfLayouts>
<url>http://192.168.205.205:8081/nexus/content/groups/public-p2/</url>
<layout>p2</layout>
</mirror>
Maybe something is wrong with this configurations? I suspect that maybe Nexus tries to mirror its own repository, leading to endless requests?