Fixes ticket #1809 - Harmonize configuration option names.
Signed-off-by: Jonas Bonér <jonas@jonasboner.com>
This commit is contained in:
parent
34d9714e22
commit
51a218b87f
21 changed files with 62 additions and 63 deletions
|
|
@ -29,10 +29,10 @@ class ConfigSpec extends AkkaSpec(ConfigFactory.defaultReference) {
|
|||
getBoolean("akka.actor.serialize-messages") must equal(false)
|
||||
settings.SerializeAllMessages must equal(false)
|
||||
|
||||
getInt("akka.scheduler.ticksPerWheel") must equal(512)
|
||||
getInt("akka.scheduler.ticks-per-wheel") must equal(512)
|
||||
settings.SchedulerTicksPerWheel must equal(512)
|
||||
|
||||
getMilliseconds("akka.scheduler.tickDuration") must equal(100)
|
||||
getMilliseconds("akka.scheduler.tick-duration") must equal(100)
|
||||
settings.SchedulerTickDuration must equal(100 millis)
|
||||
|
||||
settings.Daemonicity must be(false)
|
||||
|
|
@ -49,7 +49,7 @@ class ConfigSpec extends AkkaSpec(ConfigFactory.defaultReference) {
|
|||
c.getString("executor") must equal("fork-join-executor")
|
||||
c.getInt("mailbox-capacity") must equal(-1)
|
||||
c.getMilliseconds("mailbox-push-timeout-time") must equal(10 * 1000)
|
||||
c.getString("mailboxType") must be("")
|
||||
c.getString("mailbox-type") must be("")
|
||||
c.getMilliseconds("shutdown-timeout") must equal(1 * 1000)
|
||||
c.getInt("throughput") must equal(5)
|
||||
c.getMilliseconds("throughput-deadline-time") must equal(0)
|
||||
|
|
|
|||
|
|
@ -153,7 +153,7 @@ class PriorityMailboxSpec extends MailboxSpec {
|
|||
object CustomMailboxSpec {
|
||||
val config = """
|
||||
my-dispatcher {
|
||||
mailboxType = "akka.dispatch.CustomMailboxSpec$MyMailboxType"
|
||||
mailbox-type = "akka.dispatch.CustomMailboxSpec$MyMailboxType"
|
||||
}
|
||||
"""
|
||||
|
||||
|
|
|
|||
|
|
@ -10,10 +10,10 @@ import com.typesafe.config.Config
|
|||
object PriorityDispatcherSpec {
|
||||
val config = """
|
||||
unbounded-prio-dispatcher {
|
||||
mailboxType = "akka.dispatch.PriorityDispatcherSpec$Unbounded"
|
||||
mailbox-type = "akka.dispatch.PriorityDispatcherSpec$Unbounded"
|
||||
}
|
||||
bounded-prio-dispatcher {
|
||||
mailboxType = "akka.dispatch.PriorityDispatcherSpec$Bounded"
|
||||
mailbox-type = "akka.dispatch.PriorityDispatcherSpec$Bounded"
|
||||
}
|
||||
"""
|
||||
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ akka {
|
|||
|
||||
# Log the complete configuration at INFO level when the actor system is started.
|
||||
# This is useful when you are uncertain of what configuration is used.
|
||||
logConfigOnStart = off
|
||||
log-config-on-start = off
|
||||
|
||||
# List FQCN of extensions which shall be loaded at actor system startup.
|
||||
# Should be on the format: 'extensions = ["foo", "bar"]' etc.
|
||||
|
|
@ -37,7 +37,7 @@ akka {
|
|||
daemonic = off
|
||||
|
||||
# JVM shutdown, System.exit(-1), in case of a fatal error, such as OutOfMemoryError
|
||||
jvmExitOnFatalError = on
|
||||
jvm-exit-on-fatal-error = on
|
||||
|
||||
actor {
|
||||
|
||||
|
|
@ -185,37 +185,37 @@ akka {
|
|||
|
||||
# This will be used if you have set "executor = "thread-pool-executor""
|
||||
thread-pool-executor {
|
||||
# Keep alive time for threads
|
||||
keep-alive-time = 60s
|
||||
# Keep alive time for threads
|
||||
keep-alive-time = 60s
|
||||
|
||||
# Min number of threads to cap factor-based core number to
|
||||
core-pool-size-min = 8
|
||||
# Min number of threads to cap factor-based core number to
|
||||
core-pool-size-min = 8
|
||||
|
||||
# No of core threads ... ceil(available processors * factor)
|
||||
core-pool-size-factor = 3.0
|
||||
# No of core threads ... ceil(available processors * factor)
|
||||
core-pool-size-factor = 3.0
|
||||
|
||||
# Max number of threads to cap factor-based number to
|
||||
core-pool-size-max = 64
|
||||
# Max number of threads to cap factor-based number to
|
||||
core-pool-size-max = 64
|
||||
|
||||
# Hint: max-pool-size is only used for bounded task queues
|
||||
# minimum number of threads to cap factor-based max number to
|
||||
max-pool-size-min = 8
|
||||
# Hint: max-pool-size is only used for bounded task queues
|
||||
# minimum number of threads to cap factor-based max number to
|
||||
max-pool-size-min = 8
|
||||
|
||||
# Max no of threads ... ceil(available processors * factor)
|
||||
max-pool-size-factor = 3.0
|
||||
# Max no of threads ... ceil(available processors * factor)
|
||||
max-pool-size-factor = 3.0
|
||||
|
||||
# Max number of threads to cap factor-based max number to
|
||||
max-pool-size-max = 64
|
||||
# Max number of threads to cap factor-based max number to
|
||||
max-pool-size-max = 64
|
||||
|
||||
# Specifies the bounded capacity of the task queue (< 1 == unbounded)
|
||||
task-queue-size = -1
|
||||
# Specifies the bounded capacity of the task queue (< 1 == unbounded)
|
||||
task-queue-size = -1
|
||||
|
||||
# Specifies which type of task queue will be used, can be "array" or
|
||||
# "linked" (default)
|
||||
task-queue-type = "linked"
|
||||
# Specifies which type of task queue will be used, can be "array" or
|
||||
# "linked" (default)
|
||||
task-queue-type = "linked"
|
||||
|
||||
# Allow core threads to time out
|
||||
allow-core-timeout = on
|
||||
# Allow core threads to time out
|
||||
allow-core-timeout = on
|
||||
}
|
||||
|
||||
# How long time the dispatcher will wait for new actors until it shuts down
|
||||
|
|
@ -245,7 +245,7 @@ akka {
|
|||
# FQCN of the MailboxType, if not specified the default bounded or unbounded
|
||||
# mailbox is used. The Class of the FQCN must have a constructor with a
|
||||
# com.typesafe.config.Config parameter.
|
||||
mailboxType = ""
|
||||
mailbox-type = ""
|
||||
}
|
||||
|
||||
debug {
|
||||
|
|
@ -272,7 +272,7 @@ akka {
|
|||
}
|
||||
|
||||
# Class to Serializer binding. You only need to specify the name of an interface
|
||||
# or abstract base class of the messages. In case of ambiguity it is using the
|
||||
# or abstract base class of the messages. In case of ambiguity it is using the
|
||||
# most specific configured class, or giving a warning and choosing the “first” one.
|
||||
#
|
||||
# To disable one of the default serializers, assign its class to "none", like
|
||||
|
|
@ -294,7 +294,7 @@ akka {
|
|||
# or larger tick duration.
|
||||
# If you are scheduling a lot of tasks you should consider increasing the ticks per wheel.
|
||||
# For more information see: http://www.jboss.org/netty/
|
||||
tickDuration = 100ms
|
||||
ticksPerWheel = 512
|
||||
tick-duration = 100ms
|
||||
ticks-per-wheel = 512
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -77,7 +77,7 @@ object ActorSystem {
|
|||
final val LogLevel = getString("akka.loglevel")
|
||||
final val StdoutLogLevel = getString("akka.stdout-loglevel")
|
||||
final val EventHandlers: Seq[String] = getStringList("akka.event-handlers").asScala
|
||||
final val LogConfigOnStart = config.getBoolean("akka.logConfigOnStart")
|
||||
final val LogConfigOnStart = config.getBoolean("akka.log-config-on-start")
|
||||
final val AddLoggingReceive = getBoolean("akka.actor.debug.receive")
|
||||
final val DebugAutoReceive = getBoolean("akka.actor.debug.autoreceive")
|
||||
final val DebugLifecycle = getBoolean("akka.actor.debug.lifecycle")
|
||||
|
|
@ -89,10 +89,10 @@ object ActorSystem {
|
|||
case x ⇒ Some(x)
|
||||
}
|
||||
|
||||
final val SchedulerTickDuration = Duration(getMilliseconds("akka.scheduler.tickDuration"), MILLISECONDS)
|
||||
final val SchedulerTicksPerWheel = getInt("akka.scheduler.ticksPerWheel")
|
||||
final val SchedulerTickDuration = Duration(getMilliseconds("akka.scheduler.tick-duration"), MILLISECONDS)
|
||||
final val SchedulerTicksPerWheel = getInt("akka.scheduler.ticks-per-wheel")
|
||||
final val Daemonicity = getBoolean("akka.daemonic")
|
||||
final val JvmExitOnFatalError = getBoolean("akka.jvmExitOnFatalError")
|
||||
final val JvmExitOnFatalError = getBoolean("akka.jvm-exit-on-fatal-error")
|
||||
|
||||
if (ConfigVersion != Version)
|
||||
throw new ConfigurationException("Akka JAR version [" + Version + "] does not match the provided config version [" + ConfigVersion + "]")
|
||||
|
|
|
|||
|
|
@ -354,12 +354,12 @@ abstract class MessageDispatcherConfigurator(val config: Config, val prerequisit
|
|||
/**
|
||||
* Returns a factory for the [[akka.dispatch.Mailbox]] given the configuration.
|
||||
* Default implementation instantiate the [[akka.dispatch.MailboxType]] specified
|
||||
* as FQCN in mailboxType config property. If mailboxType is unspecified (empty)
|
||||
* as FQCN in mailbox-type config property. If mailbox-type is unspecified (empty)
|
||||
* then [[akka.dispatch.UnboundedMailbox]] is used when capacity is < 1,
|
||||
* otherwise [[akka.dispatch.BoundedMailbox]].
|
||||
*/
|
||||
def mailboxType(): MailboxType = {
|
||||
config.getString("mailboxType") match {
|
||||
config.getString("mailbox-type") match {
|
||||
case "" ⇒
|
||||
val capacity = config.getInt("mailbox-capacity")
|
||||
if (capacity < 1) UnboundedMailbox()
|
||||
|
|
|
|||
|
|
@ -19,6 +19,5 @@ akka {
|
|||
executor = thread-pool-executor
|
||||
type = PinnedDispatcher
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ akka {
|
|||
}
|
||||
|
||||
gossip {
|
||||
initialDelay = 5s
|
||||
initial-delay = 5s
|
||||
frequency = 1s
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@ class ClusterSettings(val config: Config, val systemName: String) {
|
|||
val FailureDetectorMaxSampleSize = getInt("akka.cluster.failure-detector.max-sample-size")
|
||||
val SeedNodeConnectionTimeout = Duration(config.getMilliseconds("akka.cluster.seed-node-connection-timeout"), MILLISECONDS)
|
||||
val MaxTimeToRetryJoiningCluster = Duration(config.getMilliseconds("akka.cluster.max-time-to-retry-joining-cluster"), MILLISECONDS)
|
||||
val InitialDelayForGossip = Duration(getMilliseconds("akka.cluster.gossip.initialDelay"), MILLISECONDS)
|
||||
val InitialDelayForGossip = Duration(getMilliseconds("akka.cluster.gossip.initial-delay"), MILLISECONDS)
|
||||
val GossipFrequency = Duration(getMilliseconds("akka.cluster.gossip.frequency"), MILLISECONDS)
|
||||
val SeedNodes = Set.empty[Address] ++ getStringList("akka.cluster.seed-nodes").asScala.collect {
|
||||
case AddressExtractor(addr) ⇒ addr
|
||||
|
|
|
|||
|
|
@ -172,12 +172,12 @@ More advanced include and substitution mechanisms are explained in the `HOCON <h
|
|||
specification.
|
||||
|
||||
|
||||
.. _-Dakka.logConfigOnStart:
|
||||
.. _-Dakka.log-config-on-start:
|
||||
|
||||
Logging of Configuration
|
||||
------------------------
|
||||
|
||||
If the system or config property ``akka.logConfigOnStart`` is set to ``on``, then the
|
||||
If the system or config property ``akka.log-config-on-start`` is set to ``on``, then the
|
||||
complete configuration at INFO level when the actor system is started. This is useful
|
||||
when you are uncertain of what configuration is used.
|
||||
|
||||
|
|
|
|||
|
|
@ -61,7 +61,7 @@ This config option is very good if you want to know what config settings are loa
|
|||
akka {
|
||||
# Log the complete configuration at INFO level when the actor system is started.
|
||||
# This is useful when you are uncertain of what configuration is used.
|
||||
logConfigOnStart = on
|
||||
log-config-on-start = on
|
||||
}
|
||||
|
||||
If you want very detailed logging of all automatically received messages that are processed
|
||||
|
|
@ -224,7 +224,7 @@ With Logback the thread name is available with ``%X{sourceThread}`` specifier wi
|
|||
</appender>
|
||||
|
||||
.. note::
|
||||
|
||||
|
||||
It will probably be a good idea to use the ``sourceThread`` MDC value also in
|
||||
non-Akka parts of the application in order to have this property consistently
|
||||
available in the logs.
|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@ object DurableMailboxDocSpec {
|
|||
val config = """
|
||||
//#dispatcher-config
|
||||
my-dispatcher {
|
||||
mailboxType = akka.actor.mailbox.FileBasedMailboxType
|
||||
mailbox-type = akka.actor.mailbox.FileBasedMailboxType
|
||||
}
|
||||
//#dispatcher-config
|
||||
"""
|
||||
|
|
|
|||
|
|
@ -99,7 +99,7 @@ You configure durable mailboxes through the dispatcher, as described in
|
|||
Config::
|
||||
|
||||
my-dispatcher {
|
||||
mailboxType = akka.actor.mailbox.FileBasedMailboxType
|
||||
mailbox-type = akka.actor.mailbox.FileBasedMailboxType
|
||||
}
|
||||
|
||||
You can also configure and tune the file-based durable mailbox. This is done in
|
||||
|
|
@ -124,7 +124,7 @@ You configure durable mailboxes through the dispatcher, as described in
|
|||
Config::
|
||||
|
||||
my-dispatcher {
|
||||
mailboxType = akka.actor.mailbox.RedisBasedMailboxType
|
||||
mailbox-type = akka.actor.mailbox.RedisBasedMailboxType
|
||||
}
|
||||
|
||||
You also need to configure the IP and port for the Redis server. This is done in
|
||||
|
|
@ -150,7 +150,7 @@ You configure durable mailboxes through the dispatcher, as described in
|
|||
Config::
|
||||
|
||||
my-dispatcher {
|
||||
mailboxType = akka.actor.mailbox.ZooKeeperBasedMailboxType
|
||||
mailbox-type = akka.actor.mailbox.ZooKeeperBasedMailboxType
|
||||
}
|
||||
|
||||
You also need to configure ZooKeeper server addresses, timeouts, etc. This is
|
||||
|
|
@ -173,7 +173,7 @@ You configure durable mailboxes through the dispatcher, as described in
|
|||
Config::
|
||||
|
||||
my-dispatcher {
|
||||
mailboxType = akka.actor.mailbox.BeanstalkBasedMailboxType
|
||||
mailbox-type = akka.actor.mailbox.BeanstalkBasedMailboxType
|
||||
}
|
||||
|
||||
You also need to configure the IP, and port, and so on, for the Beanstalk
|
||||
|
|
@ -202,7 +202,7 @@ You configure durable mailboxes through the dispatcher, as described in
|
|||
Config::
|
||||
|
||||
my-dispatcher {
|
||||
mailboxType = akka.actor.mailbox.MongoBasedMailboxType
|
||||
mailbox-type = akka.actor.mailbox.MongoBasedMailboxType
|
||||
}
|
||||
|
||||
You will need to configure the URI for the MongoDB server, using the URI Format specified in the
|
||||
|
|
|
|||
|
|
@ -326,7 +326,7 @@ v1.3::
|
|||
v2.0::
|
||||
|
||||
-Dconfig.file=<file path to configuration file>
|
||||
-Dakka.logConfigOnStart=on
|
||||
-Dakka.log-config-on-start=on
|
||||
|
||||
|
||||
Several configuration properties have been changed, such as:
|
||||
|
|
|
|||
|
|
@ -94,13 +94,13 @@ object DispatcherDocSpec {
|
|||
|
||||
//#prio-dispatcher-config
|
||||
prio-dispatcher {
|
||||
mailboxType = "akka.docs.dispatcher.DispatcherDocSpec$PrioMailbox"
|
||||
mailbox-type = "akka.docs.dispatcher.DispatcherDocSpec$PrioMailbox"
|
||||
}
|
||||
//#prio-dispatcher-config
|
||||
|
||||
//#prio-dispatcher-config-java
|
||||
prio-dispatcher-java {
|
||||
mailboxType = "akka.docs.dispatcher.DispatcherDocTestBase$PrioMailbox"
|
||||
mailbox-type = "akka.docs.dispatcher.DispatcherDocTestBase$PrioMailbox"
|
||||
}
|
||||
//#prio-dispatcher-config-java
|
||||
"""
|
||||
|
|
|
|||
|
|
@ -58,7 +58,7 @@ This config option is very good if you want to know what config settings are loa
|
|||
akka {
|
||||
# Log the complete configuration at INFO level when the actor system is started.
|
||||
# This is useful when you are uncertain of what configuration is used.
|
||||
logConfigOnStart = on
|
||||
log-config-on-start = on
|
||||
}
|
||||
|
||||
If you want very detailed logging of all user-level messages that are processed
|
||||
|
|
@ -257,7 +257,7 @@ With Logback the thread name is available with ``%X{sourceThread}`` specifier wi
|
|||
</appender>
|
||||
|
||||
.. note::
|
||||
|
||||
|
||||
It will probably be a good idea to use the ``sourceThread`` MDC value also in
|
||||
non-Akka parts of the application in order to have this property consistently
|
||||
available in the logs.
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@ package akka.actor.mailbox
|
|||
object BeanstalkBasedMailboxSpec {
|
||||
val config = """
|
||||
Beanstalkd-dispatcher {
|
||||
mailboxType = akka.actor.mailbox.BeanstalkBasedMailboxType
|
||||
mailbox-type = akka.actor.mailbox.BeanstalkBasedMailboxType
|
||||
throughput = 1
|
||||
}
|
||||
"""
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ import org.apache.commons.io.FileUtils
|
|||
object FileBasedMailboxSpec {
|
||||
val config = """
|
||||
File-dispatcher {
|
||||
mailboxType = akka.actor.mailbox.FileBasedMailboxType
|
||||
mailbox-type = akka.actor.mailbox.FileBasedMailboxType
|
||||
throughput = 1
|
||||
}
|
||||
"""
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ import akka.dispatch.MessageDispatcher
|
|||
object MongoBasedMailboxSpec {
|
||||
val config = """
|
||||
mongodb-dispatcher {
|
||||
mailboxType = akka.actor.mailbox.MongoBasedMailboxType
|
||||
mailbox-type = akka.actor.mailbox.MongoBasedMailboxType
|
||||
throughput = 1
|
||||
}
|
||||
"""
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@ package akka.actor.mailbox
|
|||
object RedisBasedMailboxSpec {
|
||||
val config = """
|
||||
Redis-dispatcher {
|
||||
mailboxType = akka.actor.mailbox.RedisBasedMailboxType
|
||||
mailbox-type = akka.actor.mailbox.RedisBasedMailboxType
|
||||
throughput = 1
|
||||
}
|
||||
"""
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@ import akka.actor.ActorRef
|
|||
object ZooKeeperBasedMailboxSpec {
|
||||
val config = """
|
||||
ZooKeeper-dispatcher {
|
||||
mailboxType = akka.actor.mailbox.ZooKeeperBasedMailboxType
|
||||
mailbox-type = akka.actor.mailbox.ZooKeeperBasedMailboxType
|
||||
throughput = 1
|
||||
}
|
||||
"""
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue