For further reference, please consider the following sections:
- Official Gradle documentation
- Spring Boot Gradle Plugin Reference Guide
- Create an OCI image
- Coroutines section of the Spring Framework Documentation
- GraalVM Native Image Support
- Spring Boot DevTools
- Spring Configuration Processor
- Spring Web
- Spring Reactive Web
- Spring for GraphQL
- Spring HATEOAS
- Vaadin
- Spring Data JPA
The following guides illustrate how to use some features concretely:
- Building a RESTful Web Service
- Serving Web Content with Spring MVC
- Building REST services with Spring
- Building a Reactive RESTful Web Service
- Building a GraphQL service
- Building a Hypermedia-Driven RESTful Web Service
- Creating CRUD UI with Vaadin
- Accessing Data with JPA
These additional references should also help you:
This project has been configured to use the Netflix DGS Codegen plugin.
This plugin can be used to generate client files for accessing remote GraphQL services.
The default setup assumes that the GraphQL schema file for the remote service is added to the src/main/resources/graphql-client/
location.
You can learn more about the plugin configuration options and how to use the generated types to adapt the default setup.
This project has been configured to let you generate either a lightweight container or a native executable. It is also possible to run your tests in a native image.
If you're already familiar with Spring Boot container images support, this is the easiest way to get started. Docker should be installed and configured on your machine prior to creating the image.
To create the image, run the following goal:
$ ./gradlew bootBuildImage
Then, you can run the app like any other container:
$ docker run --rm -p 8080:8080 omnibus:0.0.1-SNAPSHOT
Use this option if you want to explore more options such as running your tests in a native image.
The GraalVM native-image
compiler should be installed and configured on your machine.
NOTE: GraalVM 22.3+ is required.
To create the executable, run the following goal:
$ ./gradlew nativeCompile
Then, you can run the app as follows:
$ build/native/nativeCompile/omnibus
You can also run your existing tests suite in a native image. This is an efficient way to validate the compatibility of your application.
To run your existing tests in a native image, run the following goal:
$ ./gradlew nativeTest