building airspace simulations faster and better with actors
https://github.com/nasarace/race
~
Peter.C.Mehlitz
SGT Inc, NASA Ames Research Center
uniform programming model for components supporting:
RaceActor type hierarchy
class ProbeActor (config: Config) extends SubscribingRaceActor {
def handleMessage = {
case BusEvent(channel,msg,sender) => println(msg)
}
}
specialized Akka actors
implement underlying state model in library classes
support sequential, deterministic system-
concrete RaceActors mostly just define (user-) message handler
communicate through (configured) channels (publish/subscribe)
support location transparency (can be distributed across network)
RemoteMain driver instantiating RaceActorSystem with configRaceActorSystem instantiating Master actorMaster actor instantiating configured RaceActorsconfigs are text files with formal syntax (HOCON)
universe {
name = "mysimulation"
...
actors = [
{ name = "aircraft"
class = "gov.nasa.race.actors.SimpleAircraft"
write-to = "/flightpos"
heading = 42
...
},
{ name = "probe"
class = ...
read-from = "/flightpos"
}
...
configs define graphs:
live demo
application domain:
implementation:
RACE scales!