https://github.com/t1/wildfly-glow-demo
Demos a Jakarta EE application providing a JAX-RS and a GraphQL service, and use Glow to create a custom WildFly runtime, using it for tests.
https://github.com/t1/wildfly-glow-demo
Last synced: about 1 year ago
JSON representation
Demos a Jakarta EE application providing a JAX-RS and a GraphQL service, and use Glow to create a custom WildFly runtime, using it for tests.
- Host: GitHub
- URL: https://github.com/t1/wildfly-glow-demo
- Owner: t1
- Created: 2024-03-02T06:12:55.000Z (over 2 years ago)
- Default Branch: trunk
- Last Pushed: 2025-02-21T14:49:39.000Z (over 1 year ago)
- Last Synced: 2025-02-21T15:41:26.463Z (over 1 year ago)
- Language: Java
- Size: 40 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: README.adoc
Awesome Lists containing this project
README
= WildFly Glow Demo
Demos a https://jakarta.ee[Jakarta EE] application providing a JAX-RS and a GraphQL service, and use https://docs.wildfly.org/wildfly-glow/[Glow] to create a custom https://www.wildfly.org[WildFly] runtime, using it for integration tests.
== Running
=== During ITs
The normal Maven build executes the ITs with a locally provisioned WildFly.
As the default goal is `verify`, you can simply run:
[source,bash]
----
mvn
----
=== Dev-Mode
You can also develop/test it in WildFly dev mode, i.e. changes to your code get picked up and redeployed automatically.
Just run:
[source,bash]
----
mvn wildfly:dev -Pdevmode
----
The `-Pdevmode` profile is used to enable:
* the GraphiQL UI you can access at http://localhost:8080/graphql-ui
* the Swagger UI you can access at http://localhost:8080/rest/openapi-ui/index.html
Switching between the two modes requires a `mvn clean`, as the `ROOT.war` generated by the `wildfly:dev` mode is a directory, while the `verify` goal generates it as a file.
=== Bootable JAR
A third option is to run the bootable JAR with:
[source,bash]
----
java -jar target/server-bootable.jar
----
=== Docker
To generate a Docker image, you need the WildFly Glow CLI; it's not yet supported by the maven plugin.
You can download the latest release from https://github.com/wildfly/wildfly-glow/releases[here], unpack it `${SOMEWHERE}`, and run:
[source,bash]
----
$SOMEWHERE/wildfly-glow scan --cloud --provision=DOCKER_IMAGE target/ROOT.war
docker run --rm -it -p 8080:8080 -p 9990:9990 --name widlfly-glow-demo wildfly-glow-image-server-31_0_1_final
----