Using JDK 20+ and Maven 3.9.x, the Spring Boot starters to show off a few features for a series of articles.
This project will be added to over time as additional demos are created.
Running the ./run-with-spring-shell.sh
script will launch the Spring Boot application and then begin a Spring Shell session. Commands are defined in the ...shellui
package. The commands let the user interact with a Redis server.
Running the ./jshell.sh
script builds the project and then launches JShell, booting the Spring container and exposing it as context
in the shell itself. Any Spring component can then be accessed via getBean
on the context
object and called.
- Spring Boot BOM
- Spring boot maven plugin
- Testcontainers
- JUnit Jupiter
- Spring boot logging starter -> SLF4J (use log4j2 if so inclined for performance and adaptability, see this article.
- Spring redis starter
- Lettuce
- Jedis
- Spring WebFlux starter
Standard Maven build. use Maven 3.9.x.
- Run all unit tests with
mvn test
- Run all integration / spring tests with
mvn verify
- Build and run with
mvn spring-boot:run
- Build executable war to run with
java -jar
usingmvn package
- Build docker image with
mvn spring-boot:build-image
- Do we need both the parent AND Spring BOM?