OpenLiberty / ci.maven

Maven plugins for managing Liberty profile servers #devops
Apache License 2.0
130 stars 91 forks source link

Install features from Maven coordinates #837

Closed ggam closed 1 year ago

ggam commented 4 years ago

featureUtility now allows to install features directly from Maven: https://openliberty.io/blog/2020/06/05/graphql-open-liberty-20006.html#MVN

I can manually install adminCenter-1.0 but it doesn't work with the Maven plugin.

cherylking commented 4 years ago

Can you please explain in more detail "what doesn't work with the Maven plugin"? We already install features directly from Maven by default (for what is in server.xml or configured in the elements in pom.xml). Please provide the pom.xml, the Maven command, and any relevant additional info like contents of server.xml <featureManager> element.

cherylking commented 4 years ago

Looks like this may be an enhancement request to install features using the <dependencies> section of the pom.xml?

ggam commented 4 years ago

Excuse me for my short description! Since this didn't used to work on either place I thought the plugin would just need some adjustment to acommodate for featureUtility changes.

This the relevant part of my pom.xml:

            <plugin>
                <groupId>io.openliberty.tools</groupId>
                <artifactId>liberty-maven-plugin</artifactId>
                <version>3.2.1</version>
                <executions>
                    <execution>
                        <id>create-server</id>
                        <phase>process-resources</phase>
                        <goals>
                            <goal>create</goal>
                        </goals>
                    </execution>

                    <execution>
                        <id>package-server</id>
                        <phase>package</phase>
                        <goals>
                            <goal>install-feature</goal>
                            <goal>deploy</goal>
                            <goal>package</goal>
                        </goals>
                    </execution>
                </executions>
                <configuration>
                    <include>runnable</include>
                    <serverName>${project.name}</serverName>
                    <outputDirectory>target/wlp-package</outputDirectory>
                    <features>
                        <acceptLicense>true</acceptLicense>
                        <feature>adminCenter-1.0</feature>
                    </features>
                </configuration>
            </plugin>
        </plugins>

When I mvn clean install it:

[ERROR] Failed to execute goal io.openliberty.tools:liberty-maven-plugin:3.2.1:install-feature (package-server) on project libertybatch: CWWKF1299E: No se han podido obtener las características siguientes: adminCenter-1.0. Asegúrese de que las características sean válidas para Open Liberty. -> [Help 1]
ggam commented 4 years ago

I suspect this is due to adminCenter not being part of OpenLiberty

cherylking commented 4 years ago

Support has not been added to the Liberty Maven/Gradle plugins for this new OpenLiberty functionality yet.

yeekangc commented 4 years ago

https://github.com/OpenLiberty/open-liberty/issues/9227 is closed.

Where are we with this, @hermankailey. Cc @bensonlatibm.

cherylking commented 1 year ago

@ggam Can this issue be closed now? Has it been resolved with more recent versions of our plugin?

ggam commented 1 year ago

I'm not currently using OpenLiberty but from what I recall there was already some equivalent functionality in the latest versiones I used. So this can be closed.

El mié, 22 mar 2023 16:42, Cheryl King @.***> escribió:

@ggam https://github.com/ggam Can this issue be closed now? Has it been resolved with more recent versions of our plugin?

— Reply to this email directly, view it on GitHub https://github.com/OpenLiberty/ci.maven/issues/837#issuecomment-1479806558, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAQC44CBBFKH6Z756J7K54DW5MMWVANCNFSM4N3VO7LQ . You are receiving this because you were mentioned.Message ID: @.***>