There appears to be an issue running the validate plugin in karaf version
4.0.0.M1.  While attempting to validate a feature I'm getting the following
error:

[INFO]
------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO]
------------------------------------------------------------------------
[INFO] Total time: 37:25.221s
[INFO] Finished at: Thu Feb 12 10:15:24 CST 2015
[INFO] Final Memory: 25M/447M
[INFO]
------------------------------------------------------------------------
[ERROR] Failed to execute goal
org.apache.karaf.tooling:karaf-maven-plugin:4.0.0.M1:features-validate-descriptor
(validate) on project leo-karaf-dist: Unable to validate
/Users/e21897/Projects/leo/repo/source/leo/leo-karaf-dist/src/main/distribution/deploy/leo-features.xml:
Unable to find definition for feature aries-proxy (version 0.0.0) -> [Help
1]

Based upon preliminary investigation, it appears that
ValidateDescriptorMojo:Features.get(String name, String version) doesn't
find a feature match during getDependencyFeatureExports because the code is
looking for an exact string version match, so if the version isn't specified 
the default version "0.0.0" won't match the actual version "4.0.0.M1" but
this also doesn't seem to work for version ranges either, for example in
pax-http the specified version range of [7.0,10.0) for pax-jetty doesn't
match the specified version of "9.0.7.v20131107". As a side note, it looks
like you have to add
mvn:org.ops4j.pax.web/pax-web-features/4.0.0/xml/features as a configuration
repository for the features-validate-descriptor to work, since the karaf
standard feature has a dependency on pax-http, and additionally I had to add
the felix framework as a provided dependency because otherwise the plugin
fails trying to validate the standard aries-proxy feature with the following
missing exports...

[WARNING] Failed to validate feature aries-proxy
[WARNING] No export found to match org.osgi.util.tracker;version="[1.4,2)"
(imported by mvn:org.apache.aries/org.apache.aries.util/1.1.0)
[WARNING] No export found to match org.osgi.util.tracker;version="[1.5,2)"
(imported by mvn:org.apache.aries.proxy/org.apache.aries.proxy.impl/1.0.3)
[WARNING] No export found to match org.osgi.framework;version="[1.5,2)"
(imported by mvn:org.apache.aries.proxy/org.apache.aries.proxy.impl/1.0.3)
[WARNING] No export found to match org.osgi.framework;version="[1.5,2)"
(imported by mvn:org.apache.aries.proxy/org.apache.aries.proxy.api/1.0.1)
[WARNING] No export found to match org.osgi.framework;version="[1.5,2)"
(imported by mvn:org.apache.aries/org.apache.aries.util/1.1.0)





--
View this message in context: 
http://karaf.922171.n3.nabble.com/features-validate-descriptor-fails-in-version-4-0-0-M1-tp4038501.html
Sent from the Karaf - User mailing list archive at Nabble.com.

Reply via email to