diff --git a/liberty-maven-plugin/src/it/kernel-install-feature-test/prepare-multiple-features-it/pom.xml b/liberty-maven-plugin/src/it/kernel-install-feature-test/prepare-multiple-features-it/pom.xml
index 2d50a7618..c52ee8f16 100644
--- a/liberty-maven-plugin/src/it/kernel-install-feature-test/prepare-multiple-features-it/pom.xml
+++ b/liberty-maven-plugin/src/it/kernel-install-feature-test/prepare-multiple-features-it/pom.xml
@@ -29,25 +29,6 @@
copy-resources
-
- ${user.home}/.m2/repository/test/user/test/osgi/hello-bom/1.0
-
-
- src/test/resources
-
- hello-bom-1.0.pom
-
-
-
-
-
-
- copy-resource-two
- process-test-resources
-
- copy-resources
-
-
${user.home}/.m2/repository/test/user/test/osgi/hello-esa-plugin/1.0
@@ -61,26 +42,26 @@
- copy-resource-three
+ copy-resource-two
process-test-resources
copy-resources
- ${user.home}/.m2/repository/test/user/test/osgi/SimpleActivator-bom/1.0
+ ${user.home}/.m2/repository/test/user/test/osgi/features-bom/1.0
src/test/resources
- SimpleActivator-bom-1.0.pom
+ features-bom-1.0.pom
- copy-resource-four
+ copy-resource-three
process-test-resources
copy-resources
@@ -156,18 +137,12 @@
-
- ${bom.group.id}
- hello-bom
- 1.0
- pom
-
-
- test.user.test.osgi
- SimpleActivator-bom
- 1.0
- pom
-
+
+ test.user.test.osgi
+ features-bom
+ 1.0
+ pom
+
diff --git a/liberty-maven-plugin/src/it/verify-user-feature-it/src/test/resources/SimpleActivator-bom-1.0.pom b/liberty-maven-plugin/src/it/kernel-install-feature-test/prepare-multiple-features-it/src/test/resources/features-bom-1.0.pom
similarity index 64%
rename from liberty-maven-plugin/src/it/verify-user-feature-it/src/test/resources/SimpleActivator-bom-1.0.pom
rename to liberty-maven-plugin/src/it/kernel-install-feature-test/prepare-multiple-features-it/src/test/resources/features-bom-1.0.pom
index fa36c3706..576fd24b0 100644
--- a/liberty-maven-plugin/src/it/verify-user-feature-it/src/test/resources/SimpleActivator-bom-1.0.pom
+++ b/liberty-maven-plugin/src/it/kernel-install-feature-test/prepare-multiple-features-it/src/test/resources/features-bom-1.0.pom
@@ -2,7 +2,7 @@
4.0.0
test.user.test.osgi
- SimpleActivator-bom
+ features-bom
1.0
pom
@@ -15,5 +15,16 @@
esa
+
+
+
+ test.user.test.osgi
+
+ ${esa.artifact.id}
+ 1.0
+ esa
+ runtime
+
+
diff --git a/liberty-maven-plugin/src/it/kernel-install-feature-test/prepare-multiple-features-it/src/test/resources/hello-bom-1.0.pom b/liberty-maven-plugin/src/it/kernel-install-feature-test/prepare-multiple-features-it/src/test/resources/hello-bom-1.0.pom
deleted file mode 100644
index 52996e7d8..000000000
--- a/liberty-maven-plugin/src/it/kernel-install-feature-test/prepare-multiple-features-it/src/test/resources/hello-bom-1.0.pom
+++ /dev/null
@@ -1,26 +0,0 @@
-
-
- 4.0.0
-
- test.user.test.osgi
- hello-bom
- 1.0
- pom
- user features bill of materials
- user features bill of materials
- https://openliberty.io/
-
-
-
-
- test.user.test.osgi
-
- ${esa.artifact.id}
- 1.0
- esa
- runtime
-
-
-
-
diff --git a/liberty-maven-plugin/src/it/verify-user-feature-it/pom.xml b/liberty-maven-plugin/src/it/verify-user-feature-it/pom.xml
index d8d04bf4a..383190459 100644
--- a/liberty-maven-plugin/src/it/verify-user-feature-it/pom.xml
+++ b/liberty-maven-plugin/src/it/verify-user-feature-it/pom.xml
@@ -41,12 +41,12 @@
- ${user.home}/.m2/repository/test/user/test/osgi/SimpleActivator-bom/1.0
+ ${user.home}/.m2/repository/test/user/test/osgi/features-bom/1.0
src/test/resources
- SimpleActivator-bom-1.0.pom
+ features-bom-1.0.pom
@@ -159,7 +159,7 @@
test.user.test.osgi
- SimpleActivator-bom
+ features-bom
1.0
pom
diff --git a/liberty-maven-plugin/src/it/kernel-install-feature-test/prepare-multiple-features-it/src/test/resources/SimpleActivator-bom-1.0.pom b/liberty-maven-plugin/src/it/verify-user-feature-it/src/test/resources/features-bom-1.0.pom
similarity index 93%
rename from liberty-maven-plugin/src/it/kernel-install-feature-test/prepare-multiple-features-it/src/test/resources/SimpleActivator-bom-1.0.pom
rename to liberty-maven-plugin/src/it/verify-user-feature-it/src/test/resources/features-bom-1.0.pom
index fa36c3706..5b3078179 100644
--- a/liberty-maven-plugin/src/it/kernel-install-feature-test/prepare-multiple-features-it/src/test/resources/SimpleActivator-bom-1.0.pom
+++ b/liberty-maven-plugin/src/it/verify-user-feature-it/src/test/resources/features-bom-1.0.pom
@@ -2,7 +2,7 @@
4.0.0
test.user.test.osgi
- SimpleActivator-bom
+ features-bom
1.0
pom
diff --git a/liberty-maven-plugin/src/main/java/io/openliberty/tools/maven/InstallFeatureSupport.java b/liberty-maven-plugin/src/main/java/io/openliberty/tools/maven/InstallFeatureSupport.java
index fa5c1855b..61f1c19a6 100644
--- a/liberty-maven-plugin/src/main/java/io/openliberty/tools/maven/InstallFeatureSupport.java
+++ b/liberty-maven-plugin/src/main/java/io/openliberty/tools/maven/InstallFeatureSupport.java
@@ -156,15 +156,16 @@ protected List getAdditionalJsonList() {
List result = new ArrayList();
org.apache.maven.model.DependencyManagement dependencyManagement = project.getDependencyManagement();
if(dependencyManagement == null) {
- getLog().debug("Feature-bom is not provided by the user");
+ getLog().debug("Features-bom is not provided by the user");
return null;
}
List dependencyManagementArtifacts = dependencyManagement.getDependencies();
for (org.apache.maven.model.Dependency dependencyArtifact: dependencyManagementArtifacts){
- if (("pom").equals(dependencyArtifact.getType())) {
+ if (("pom").equals(dependencyArtifact.getType()) && ("features-bom").equals(dependencyArtifact.getArtifactId())) {
String coordinate = String.format("%s:%s:%s",
dependencyArtifact.getGroupId(), FEATURES_JSON_ARTIFACT_ID, dependencyArtifact.getVersion());
result.add(coordinate);
+ getLog().debug("Features-bom is provided by the user");
getLog().info("Additional user feature json coordinate: " + coordinate);
}
}
diff --git a/liberty-maven-plugin/src/main/java/io/openliberty/tools/maven/PrepareFeatureSupport.java b/liberty-maven-plugin/src/main/java/io/openliberty/tools/maven/PrepareFeatureSupport.java
index a4ac003c5..5ab10fe6a 100644
--- a/liberty-maven-plugin/src/main/java/io/openliberty/tools/maven/PrepareFeatureSupport.java
+++ b/liberty-maven-plugin/src/main/java/io/openliberty/tools/maven/PrepareFeatureSupport.java
@@ -110,7 +110,7 @@ protected List getDependencyBOMs() {
if (dependencyManagement != null) {
List dependencyManagementArtifacts = dependencyManagement.getDependencies();
for (org.apache.maven.model.Dependency dependencyArtifact: dependencyManagementArtifacts){
- if (("pom").equals(dependencyArtifact.getType())) {
+ if (("pom").equals(dependencyArtifact.getType()) && ("features-bom").equals(dependencyArtifact.getArtifactId()) ) {
String coordinate = String.format("%s:%s:%s",
dependencyArtifact.getGroupId(), dependencyArtifact.getArtifactId(), dependencyArtifact.getVersion());
result.add(coordinate);