Code challenge featuring event-driven architecture with Akka — implementation of the Actor Model on the JVM.
-
Make sure you have PostgreSQL server running at coordinates specified in
persistence.conf. You can launch it in docker by executingdocker-compose up postgresin thedockerdirectory (have docker-engine and docker-compose installed). -
The project comes with Run Configurations for IntelliJ IDEA. Start any of the
node1,node2, ornode3(or any combination of them). HTTP endpoint will be available on ports 8081, 8082, and 8083 respectively.
Alternatively, you can use docker-compose to start three nodes with NGINX as a simple load-balancer in round-robin configuration.
First, build the project with ./gradlew build and then execute docker-compose up in the docker directory.
NGINX will be available at http://localhost:9000
For tests that require third-party software running alongside the application (for example, PostgreSQL) testcontainers is used. Before running integration tests make sure you have docker-engine installed and running.
You can run integration tests either from your IDE or, alternatively, by executing ./gradlew integrationTest