that was one hell of a FIXME

- fixed so that netty pipeline when generating addresses does not need
  to know the system name of the connecting client (which might differ
  from the local one, of course)
- this entailed differentiating between transport addresses and system
  addresses, which I took as an opportunity to separate everything out
  properly so that address schemas can easily be made pluggable
- made RemoteSupport generic in the address format it supports
- adapt netty stuff, and made everything else work with the most
  generic: ParsedTransportAddress
- did I mention that I statically separated unparsed from parsed
  addresses?
This commit is contained in:
Roland 2011-12-11 20:00:26 +01:00
parent 40654227b7
commit 7f0275bca2
18 changed files with 357 additions and 231 deletions

View file

@ -26,7 +26,9 @@ class RemoteSettings(val config: Config, val systemName: String) extends Extensi
// TODO cluster config will go into akka-cluster-reference.conf when we enable that module
val ClusterName = getString("akka.cluster.name")
val SeedNodes = Set.empty[RemoteAddress] ++ getStringList("akka.cluster.seed-nodes").asScala.toSeq.map(RemoteAddress(_, systemName))
val SeedNodes = Set.empty[RemoteNettyAddress] ++ getStringList("akka.cluster.seed-nodes").asScala.collect {
case RemoteAddressExtractor(addr) addr.transport
}
val NodeName: String = config.getString("akka.cluster.nodename") match {
case "" throw new ConfigurationException("akka.cluster.nodename configuration property must be defined")
@ -73,5 +75,8 @@ class RemoteSettings(val config: Config, val systemName: String) extends Extensi
val ConnectionTimeout = Duration(config.getMilliseconds("akka.remote.server.connection-timeout"), MILLISECONDS)
val Backlog = config.getInt("akka.remote.server.backlog")
// TODO handle the system name right and move this to config file syntax
val URI = "akka://sys@" + Hostname + ":" + Port
}
}