Micronaut Framework codebase containing real world examples (CRUD, auth, advanced patterns, etc) that adheres to the RealWorld spec and API
This codebase was created to demonstrate a fully fledged fullstack application built with Micronaut including CRUD operations, authentication, routing, pagination, and more.
We've gone to great lengths to adhere to the Micronaut community styleguides & best practices.
For more information on how this works with other frontends/backends, head over to the RealWorld repo.
Check out the live application on Render:
Resource | URL |
---|---|
api | https://realworld-backend-micronaut.onrender.com/api |
swagger-ui | https://realworld-backend-micronaut.onrender.com/swagger-ui |
💡 The application is deployed on a free tier, so it may take a few seconds to start.
- Micronaut Framework
- Micronaut Data JPA with Hibernate
- Micronaut Liquibase for the database changes management
- Micronaut Declarative HTTP Clients for integration tests
- Micronaut Security JWT for authentication and authorization
- Micronaut Management built-in endpoints
- Micronaut OpenAPI/Swagger
- H2 in memory database
- GraalVM support
- Github Actions
- Building jar
- Building GraalVM native image for Linux, macOS, and Windows
- Building Docker image with the native executable and pushing it to GitHub Container Registry
- Execution of Realworld Postman collection with newman for all the builds
- Code coverage with Codecov
- Publishing GitHub release with the artifacts
- Triggering deployment on Render
Note that Java 17 or above is required to build the project with Gradle.
Run the application with Gradle:
./gradlew run
Or download the latest artifact from the releases page, and run:
java -jar realworld-backend-micronaut-*.jar
Run the application with Gradle:
./gradlew nativeRun
Or download the latest artifact for your platform from the releases page, unpack, and run the executable:
./realworld-backend-micronaut
Run the application with Docker:
docker run -p 8080:8080 ghcr.io/alexey-lapin/realworld-backend-micronaut:latest
The entry point address of the backend API is at http://localhost:8080/api
The repository contains a lot of test cases to cover both api test and repository test.
./gradlew test