Make cluster tests run with artery #21204
This commit is contained in:
parent
6191f39565
commit
90193907fe
9 changed files with 286 additions and 264 deletions
|
|
@ -10,6 +10,7 @@ import org.scalatest.BeforeAndAfter
|
|||
import akka.remote.testkit.MultiNodeConfig
|
||||
import akka.remote.testkit.MultiNodeSpec
|
||||
import akka.testkit._
|
||||
|
||||
import scala.concurrent.duration._
|
||||
import akka.actor.Address
|
||||
import akka.actor.ActorSystem
|
||||
|
|
@ -18,6 +19,7 @@ import akka.actor.Actor
|
|||
import akka.actor.RootActorPath
|
||||
import akka.cluster.MemberStatus._
|
||||
import akka.actor.Deploy
|
||||
import akka.remote.RARP
|
||||
|
||||
object RestartFirstSeedNodeMultiJvmSpec extends MultiNodeConfig {
|
||||
val seed1 = role("seed1")
|
||||
|
|
@ -52,8 +54,12 @@ abstract class RestartFirstSeedNodeSpec
|
|||
|
||||
lazy val restartedSeed1System = ActorSystem(
|
||||
system.name,
|
||||
ConfigFactory.parseString("akka.remote.netty.tcp.port=" + seedNodes.head.port.get).
|
||||
withFallback(system.settings.config))
|
||||
ConfigFactory.parseString(
|
||||
if (RARP(system).provider.remoteSettings.Artery.Enabled)
|
||||
"akka.remote.artery.port=" + seedNodes.head.port.get
|
||||
else
|
||||
"akka.remote.netty.tcp.port=" + seedNodes.head.port.get
|
||||
).withFallback(system.settings.config))
|
||||
|
||||
override def afterAll(): Unit = {
|
||||
runOn(seed1) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue