This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ########################################################### | |
// | |
// Demonstrates how to supervise an Akka consumer actor. | |
// | |
// The consumer consumes messages from a file endpoint: | |
// - successful message processing by the consumer will | |
// positively acknowledge the message receipt, causing | |
// the file endpoint to delete the file. | |
// - an exception during message processing will cause a | |
// supervisor to restart the consumer. Before restart, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import scala.collection.mutable.ListBuffer | |
import akka.actor.{Actor,ActorRef} | |
import akka.actor.Actor._ | |
import akka.routing.{ Listeners, Listen } | |
//Represents a domain event | |
trait Event | |
//A builder to create domain entities | |
trait EntityBuilder[Entity] { |
NewerOlder