Skip to content
/ vanir Public

A project containing 2 Spring WebFlux projects written in Kotlin. This will show how they can connect on a network, as well as other integrations.

License

Notifications You must be signed in to change notification settings

violabs/vanir

Repository files navigation

Vanir

A project demonstrating 2 applications using WebFlux to asynchronously communicate with each other.

Architecture

Miro board

Running the project

Start up docker containers (Production like)

There are shell scripts in ./scripts that will build and run the docker containers for you. There are IntelliJ run configurations for these scripts in the .run directory.

To run both apps on a docker network, run the following command in the root directory of the project:

With logs

docker compose up -f docker-compose.branch.yml
docker compose down -f docker-compose.branch.yml

Without logs

docker compose up -f docker-compose.branch.yml -d
docker compose down -f docker-compose.branch.yml -d

Start up docker containers (Freya)

Navigate to the project directory and run docker compose up. Otherwise you can use the following commands:

Without app

docker compose up -f ./freya/docker-compose.yml
docker compose down -f ./freya/docker-compose.yml

With app

docker compose up -f ./freya/docker-compose.branch.yml

docker compose down -f ./freya/docker-compose.branch.yml

Start up docker containers (Freyr)

Navigate to the project directory and run docker compose up. Otherwise you can use the following commands:

Without app

docker compose up -f ./freyr/docker-compose.yml
docker compose down -f ./freyr/docker-compose.yml

With app

docker compose up -f ./freyr/docker-compose.branch.yml
docker compose down -f ./freyr/docker-compose.branch.yml

Postman

Once this is finalized, I will add postman config under the folder /postman

Run in Postman

TODO

Flow - Endpoint to call to reserve a book for

All

  • Docker Kafka (network)
  • E2E testing with both services

Freya

  • Docker Postgres
  • Postgres DB Setup
  • Endpoint
  • Docker Kafka (individual)
  • Kafka Consumer (Order)
  • Kafka Producer (User)
  • Setup Book
  • Setup Library (UserBooks)

Freyr

  • Docker Redis
  • Endpoint
  • Docker Kafka (individual)
  • Kafka Consumer (User)
  • Kafka Producer (Order)

Design

img.png

References

About

A project containing 2 Spring WebFlux projects written in Kotlin. This will show how they can connect on a network, as well as other integrations.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published