Skip to content

dougschroeder/spring-reactive-graphql-poc

 
 

Repository files navigation

Spring Reactive GraphQL POC

This project is meant to be my own playground for learning some of the latest Spring technologies, particularly in the context of building reactive applications with GraphQL.

It uses Spring Boot, Spring GraphQL, Spring WebFlux, Spring Modulith, and MongoDB for persistence.

Getting Started

To get started with this project, you can clone the repository and run the following command to build and run the application:

./gradlew bootRun

This will start the application on port 8080 by default. You can then access the GraphQL endpoint at http://localhost:8080/graphql. You can also run the application in development mode with hot reloading by using:

./gradlew bootRun --continuous

This will allow you to make changes to the code and see them reflected immediately without needing to restart the application. You can also build a Docker image of the application using the following command:

./gradlew bootBuildImage

This will create a Docker image that you can run with:

docker run -p 8080:8080 <image-name>

You can also build an OCI image using:

./gradlew bootBuildOciImage

This will create an OCI image that can be used in container orchestration platforms like Kubernetes.

Features

  • GraphQL: The project uses Spring for GraphQL to provide a flexible API for querying and mutating data.
  • Reactive Programming: It leverages Spring WebFlux for building reactive applications, allowing for non-blocking I/O operations.
  • MongoDB: The application uses Spring Data MongoDB for reactive data access, enabling efficient data operations in a non-blocking manner.
  • Spring Modulith: This project is structured using Spring Modulith, which helps in organizing the codebase into modules, promoting separation of concerns and modularity.
  • DevTools: Spring Boot DevTools is included for development convenience, providing features like automatic restarts and live reload.
  • Docker and OCI Support: The project can be packaged as a Docker image or OCI image, making it easy to deploy in containerized environments.
  • Testing: The project includes a comprehensive test suite using JUnit 5 and Spring's testing support, ensuring the reliability of the application.
  • Documentation: The project is well-documented, with a focus on providing clear instructions for setup, usage, and development.

Reference Documentation

For further reference, please consider the following sections:

Guides

The following guides illustrate how to use some features concretely:

Additional Links

These additional references should also help you:

About

My own playground for learning some of the latest Spring technologies, particularly in the context of building reactive applications with GraphQL

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages

  • Java 96.4%
  • Dockerfile 3.6%