playframework 2.0 - Akka actor externalizing deployment configuration -
i instantiating actor in play 2.1.5 application using
lazy val ref = akka.system.actorof(props[backgroundprocessoractor], name = "background-processor")
i have properties file specifies following configuration
application { akka { actor { default-dispatcher = { fork-join-executor { parallelism-factor = 1.0 } } background-dispatcher = { fork-join-executor { parallelism-factor = 1.0 } } deployment = { /background-processor = { dispatcher = background-dispatcher router = round-robin nr-of-instances = 128 } /solr_asset_updater = { dispatcher = default-dispatcher } /solr_asset_log_updater = { dispatcher = default-dispatcher } /change_queue_processor = { dispatcher = default-dispatcher } } } } }
i spent time reading docs , source code play. deployment settings background-processor
router = round-robin
, nr-of-instances = 128
not seem taking.
is necessary specify
lazy val ref = akka.system.actorof(props[backgroundprocessoractor].withrouter(fromconfig()), name = "background-processor")
which me seems redundant. missing?
the actor system in play's akka plugin named application
, uses top-level configuration (not sub-config). can test setting log level.
akka { loglevel = "debug" actor { ... } }
Comments
Post a Comment