Workaround broken upstream features 91/65891/1
authorRobert Varga <robert.varga@pantheon.tech>
Fri, 24 Nov 2017 13:49:28 +0000 (14:49 +0100)
committerRobert Varga <robert.varga@pantheon.tech>
Fri, 24 Nov 2017 13:49:28 +0000 (14:49 +0100)
hibernate-validator-osgi-karaf-features-[5.3.4,5.4.2) is broken
due to invalid maven URL reference. Add hard exception to fix it up.

Change-Id: I6cc28817b721fd7fa6f7dd940c82a4b80acb81c2
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
karaf-plugin/src/main/java/org/opendaylight/odlparent/FeatureUtil.java
karaf/test-distribution/pom.xml

index 99b4731c729304c32ee5d89716310600b31ce119..664e47b8627caeca724bcc279c632aac76a43cf4 100644 (file)
@@ -70,6 +70,14 @@ public final class FeatureUtil {
     public static String toCoord(final URL url) throws MalformedURLException {
         String repository = url.toString();
         String unwrappedRepo = WRAP_PATTERN.matcher(repository).replaceFirst("");
+
+        // FIXME: this is a hack to deal with broken upstream repo and should be removed once karaf moves
+        //        to hibernate-validator-osgi-features-5.4.2+
+        if ("mvn:com.thoughtworks.paranamer:paranamer:2.8".equals(unwrappedRepo)) {
+            LOG.info("Working around broken hibernate-validator-osgi-karaf-features...");
+            unwrappedRepo = "mvn:com.thoughtworks.paranamer/paranamer/2.8";
+        }
+
         Parser parser = new Parser(unwrappedRepo);
         String coord = MVN_PATTERN.matcher(parser.getGroup()).replaceFirst("") + ":" + parser.getArtifact();
         if (parser.getType() != null) {
index e657b97d702d6686a747c18f22cc7800b7899969..1cce56e8d66ac65a7deb92f64e4449dbb1cfdd0d 100644 (file)
@@ -26,7 +26,7 @@
         <!-- Project local features -->
         <dependency>
             <groupId>org.opendaylight.odlparent</groupId>
-            <artifactId>odl-guava-23</artifactId>
+            <artifactId>features-odlparent</artifactId>
             <version>${project.version}</version>
             <classifier>features</classifier>
             <type>xml</type>