akka-microservice

Example of a microservice with Scala, Akka, Spray and Camel/ActiveMQ

Microservice example

Example of a microservice with Scala, Akka, Spray and Camel/ActiveMQ. Based on one of the Typesafe Activator templates.

Project contains: - Easy to test Akka system with a sample actor - Spray-based RESTful API with full CORS support - Actor and API sample tests - Camel/ActiveMQ extension for a handy integration with Akka system - Typesafe config with different profiles for production and testing environments - Logback-SLF4J logging - Sbt assembly plugin for JAR-file creation with custom merge strategy

API structure

POST /api/example1/test                           (Example1Routes)
GET  /api/example1/done                           (Example1Routes)
GET  /api/example1/service/{serviceID}/{command}  (Example1Routes)
GET  /api/example2                                (Example2Routes)

Build & Run

To run simply use:

sbt run

Run tests with:

sbt test

To build & run:

sbt assembly

And then run JAR as usual, something like this:

nohup java -jar target/scala-2.11/akka-microservice-assembly-1.0.jar 1>/dev/null 2>&1 &

Related Repositories

akka-http-microservice

akka-http-microservice

Example of (micro)service written in Scala & akka-http ...

reactive-microservices

reactive-microservices

Project showcasing different microservice communication styles using Scala, Akka, Play and other tools from Scala ecosystem ...

akka-microservice

akka-microservice

Example of a microservice with Scala, Akka, Spray and Camel/ActiveMQ ...

james

james

Base REST microservice based on akka-http ...

akka-persistence-java-example

akka-persistence-java-example

This is an Event sourced microservice example implemented using Java, Dropwizard and Akka Persistence ...