Skip to content

Commit

Permalink
OWB-1446 move guess sample to cargo-m-p
Browse files Browse the repository at this point in the history
  • Loading branch information
struberg committed Oct 16, 2024
1 parent 45e5787 commit d531bd9
Show file tree
Hide file tree
Showing 2 changed files with 57 additions and 13 deletions.
23 changes: 12 additions & 11 deletions samples/guess/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -21,14 +21,15 @@ under the License.
<parent>
<groupId>org.apache.openwebbeans</groupId>
<artifactId>samples</artifactId>
<version>4.0.0-SNAPSHOT</version>
<version>4.0.3-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>

<modelVersion>4.0.0</modelVersion>
<groupId>org.apache.openwebbeans.samples</groupId>
<artifactId>guess</artifactId>
<packaging>war</packaging>

<name>Sample Guess Application</name>
<description>Simple login application</description>

Expand All @@ -40,8 +41,8 @@ under the License.
<finalName>guess</finalName>
<plugins>
<plugin>
<groupId>org.apache.tomcat.maven</groupId>
<artifactId>tomcat7-maven-plugin</artifactId>
<groupId>org.codehaus.cargo</groupId>
<artifactId>cargo-maven3-plugin</artifactId>
</plugin>
</plugins>
</build>
Expand All @@ -57,8 +58,8 @@ under the License.

<!-- Servlet API -->
<dependency>
<groupId>org.apache.geronimo.specs</groupId>
<artifactId>geronimo-servlet_3.0_spec</artifactId>
<groupId>org.apache.tomcat</groupId>
<artifactId>tomcat-servlet-api</artifactId>
<scope>provided</scope>
</dependency>

Expand All @@ -82,18 +83,18 @@ under the License.
<version>${project.version}</version>
</dependency>

<!-- JSR-299 API -->
<dependency>
<groupId>jakarta.enterprise</groupId>
<artifactId>jakarta.enterprise.cdi-api</artifactId>
</dependency>

<!-- JSR-330 API -->
<dependency>
<groupId>jakarta.inject</groupId>
<artifactId>jakarta.inject-api</artifactId>
</dependency>

<!-- JSR-299 API -->
<dependency>
<groupId>jakarta.enterprise</groupId>
<artifactId>jakarta.enterprise.cdi-api</artifactId>
</dependency>

<!-- JSR-250 API -->
<dependency>
<groupId>jakarta.annotation</groupId>
Expand Down
47 changes: 45 additions & 2 deletions samples/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,19 @@ under the License.
<name>OWB Samples</name>
<description>Apache OpenWebBeans Samples contains samples project for openwebbeans.</description>

<!--
Start the samples with
$> mvn cargo:run
To debug an application please activate the 'cargoDebug' profile and attach to port 8000
$> mvn cargo:run -PcargoDebug
-->

<properties>
<deploy.skip>false</deploy.skip>
<tomcat.port>8080</tomcat.port>
<cargo.debug.args></cargo.debug.args>
</properties>

<build>
Expand All @@ -42,10 +53,31 @@ under the License.
<groupId>org.codehaus.cargo</groupId>
<artifactId>cargo-maven3-plugin</artifactId>
<configuration>
<container>
<containerId>tomcat10x</containerId>
<artifactInstaller>
<groupId>org.apache.tomcat</groupId>
<artifactId>tomcat</artifactId>
<version>${tomcat.version}</version>
</artifactInstaller>
</container>
<deployables>
<deployable>
<type>war</type>
<location>${project.build.directory}/${project.build.finalName}.war</location>
<properties>
<context>/${project.build.finalName}</context>
</properties>
</deployable>
</deployables>
<configuration>

<properties>
<cargo.servlet.port>${tomcat.port}</cargo.servlet.port>
<cargo.start.jvmargs>${cargo.debug.args}</cargo.start.jvmargs>
</properties>
</configuration>
</configuration>

</plugin>
</plugins>
</pluginManagement>
Expand Down Expand Up @@ -106,12 +138,23 @@ under the License.
</build>
<modules>
<module>standalone-sample</module>
<!--
<module>guess</module>
<!--
<module>conversation-sample</module>
<module>jsf2sample</module>
<module>reservation</module>
<module>tomcat7-sample</module>
-->
</modules>

<profiles>
<profile>
<id>cargoDebug</id>
<properties>
<cargo.debug.args>
-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=8000 -Xnoagent
</cargo.debug.args>
</properties>
</profile>
</profiles>
</project>

0 comments on commit d531bd9

Please sign in to comment.