Skip to content

fuse-mars/spring-akka-query

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Akka-spring-command

Spring project that uses Akka internally and uses C in CQRS pattern

Value

This application is an example of a Spending Management System. You can use it to record your breakfast, Lunch and Dinner expenses!

Simple explanation of the code

User sends a request (restfull) to save a record, the controller then creates a command asking the writeWorker to write this record to db. Note: command is the record to be saved (for simplicity)

For Reading, it's the same except it does not work well since there is no way to listen to messages from the readWorker (currently)

It has two working API's

  • /api/expenses/write?name=&amount=
  • /api/expenses/read?id=

Here is an example usage

You will need to look into the code (akka package specifically) to know what is going on.

pre-requisite

  • java 8
  • gradle 2.4

Running

  • gradle build
  • gradle bootRun