PetStore Application

Introduction

MicroProfile Starter has generated this MicroProfile application for you.

This project uses Quarkus, the Supersonic Subatomic Java Framework.

If you want to learn more about Quarkus, please visit its website: https://quarkus.io/ .

Packaging and running the application

If you want to build an ??ber-jar, execute the following command:

./gradlew build -Dquarkus.package.type=uber-jar

To run the application:

java -jar build/petstore-runner.jar

The application can be also packaged using simple:

./gradlew build

It produces the quarkus-run.jar file in the build/quarkus-app/ directory. Be aware that it is not an ??ber-jar as the dependencies are copied into the build/quarkus-app/lib/ directory.

To launch the test page, open your browser at the following URL

http://localhost:8080/index.html

Running the application in dev mode

You can run your application in dev mode that enables live coding using:

./gradlew quarkusDev

NOTE: Quarkus now ships with a Dev UI, which is available in dev mode only at http://localhost:8080/q/dev/.

Creating a native executable

Mind having GRAALVM_HOME set to your Mandrel or GraalVM installation.

You can create a native executable using:

./gradlew build -Dquarkus.package.type=native

Or, if you don't have Mandrel or GraalVM installed, you can run the native executable build in a container using:

./gradlew build -Dquarkus.package.type=native -Dquarkus.native.container-build=true

Or to use Mandrel distribution:

./gradlew build -Dquarkus.package.type=native -Dquarkus.native.container-build=true -Dquarkus.native.builder-image=quay.io/quarkus/ubi-quarkus-mandrel:20.3-java11

You can then execute your native executable with:

./build/petstore-runner