Closed ops4j-issues closed 15 years ago
Alin Dreghiciu commented
When did you test this issue?
We have a similar issue in Pax Runner ( PAXRUNNER-232 ) that I solved in 13 April.
Can you test it again? And if it still fails please send me the C:\Dokumente und Einstellungen[myUsername]\Desktop\osgi-test\runner\deploy-pom.xml file
OlafO commented
Hi Alin,
I tested this today (2 hours ago) with the scripts obtained from [http://repo1.maven.org/maven2/org/ops4j/pax/construct/scripts/[1.4](http://repo1.maven.org/maven2/org/ops4j/pax/construct/scripts/[1.4)|1.3].
Here is the pom from the runner subdirectory:
<?xml version="1.0" encoding="UTF-8"?>
<project>
<modelVersion>4.0.0</modelVersion>
<groupId>com.aperto.osgi.test.build</groupId>
<artifactId>deployment</artifactId>
<version>1.0-SNAPSHOT</version>
<packaging>pom</packaging>
<name>com.aperto.osgi.test (OSGi project)</name>
<description>Generated using Pax-Construct</description>
<repositories>
<repository>
<snapshots>
<enabled>false</enabled>
</snapshots>
<id>central</id>
<name>Maven Repository Switchboard</name>
<url>http://repo1.maven.org/maven2</url>
</repository>
</repositories>
<properties>
<org.osgi.service.http.port>8080</org.osgi.service.http.port>
<org.osgi.service.http.port.secure>8443</org.osgi.service.http.port.secure>
</properties>
</project>
Best,
Olaf
Alin Dreghiciu commented
The problem was also discussed on the mailing list and after testing latest Pax Construct here is my conclusion:
The problem is due to the fact that Pax Construct specifies the --repositories options to an exact value as in for example (no other repositories defined in project): --repositories=http://repo1.maven.org/maven2,http://repository.ops4j.org/maven2/
In this case Pax Runner will not add the profiles repository to the list of repositories, due to the fact that in case that the value does not start with an plus :heavy_plus_sign: I consider that the user (Pax Construct) wants EXACTLY only those repositories and nothing else.This is a feature form Pax Runner perspective but a bug the context of Pax Construct.
For now the only solution is that you add the repository to your project or into settings.xml or you use the solution you posted of using --repositories.
Stuart McCulloch commented
This should no longer be an issue now we have the profiles in the OPS4J Maven repository (and in the future on Central).
OlafO created PAXCONSTRUCT-106
When running pax-provision in a newly created project (using pax-create-project), starting felix fails when attempting to load the profile bundle:
Pax Runner (0.18.0) from OPS4J - http://www.ops4j.org
-----------------------------------------------------
-> Using config classpath:META-INF/runner.properties
-> Using only arguments from command line
-> Scan bundles from [C:\Dokumente und EinstellungenmyUsername\Desktop\osgi-test\runner\deploy-pom.xml]
-> Scan bundles from [scan-pom:file:/C:/Dokumente und Einstellungen/myUsername/Desktop/osgi-test/runner/deploy-pom.xml]
-> Using property org.osgi.service.http.port=8080
-> Using property org.osgi.service.http.port.secure=8443
-> Scan bundles from scan-composite:mvn:org.ops4j.pax.runner.profiles/minimal//composite
_
/ /
/ / Oops, there has been a problem!
/ /
/_/ URL mvn:org.ops4j.pax.runner.profiles/minimal//composite could not be resolved.
/__/ Use --log=debug to see details.
It appears the configuration is missing the profile bundles repository.
Adding it to the pax-runner parameters project's root pom.xml solves this issue:
...
<provision>
<param>--platform=felix</param>
<param>--profiles=minimal</param>
<param>--repositories=+http://scm.ops4j.org/repos/ops4j/projects/pax/runner-repository/</param>
</provision>
...
This problem does not seem to occur when running under linux.
Affects: 1.3, 1.4 Fixed in: 1.5 Votes: 0, Watches: 1