Skip to content

Commit

Permalink
Disable serialization warnings in akka test suites akka#21882
Browse files Browse the repository at this point in the history
  • Loading branch information
johanandren authored Nov 23, 2016
1 parent 173a3aa commit 2679be5
Show file tree
Hide file tree
Showing 26 changed files with 32 additions and 22 deletions.
3 changes: 2 additions & 1 deletion akka-cluster-metrics/src/test/resources/reference.conf
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
akka {
actor {
serialize-creators = on
serialize-messages = on
serialize-messages = on
warn-about-java-serializer-usage = off
}
}
1 change: 1 addition & 0 deletions akka-cluster-sharding/src/test/resources/reference.conf
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,6 @@ akka {
actor {
serialize-creators = on
serialize-messages = on
warn-about-java-serializer-usage = off
}
}
1 change: 1 addition & 0 deletions akka-cluster-tools/src/test/resources/reference.conf
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,6 @@ akka {
actor {
serialize-creators = on
serialize-messages = on
warn-about-java-serializer-usage = off
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ object MultiNodeClusterSpec {

def clusterConfig: Config = ConfigFactory.parseString(s"""
akka.actor.provider = cluster
akka.actor.warn-about-java-serializer-usage = off
akka.cluster {
jmx.enabled = off
gossip-interval = 200 ms
Expand Down
1 change: 1 addition & 0 deletions akka-contrib/src/test/resources/reference.conf
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ akka {
actor {
serialize-creators = on
serialize-messages = on
warn-about-java-serializer-usage = off
}
remote.netty.tcp.port = 0
}
7 changes: 5 additions & 2 deletions akka-distributed-data/src/test/resources/reference.conf
Original file line number Diff line number Diff line change
@@ -1,2 +1,5 @@
akka.actor.serialize-messages = on
akka.actor.serialize-creators = on
akka.actor {
serialize-messages = on
serialize-creators = on
warn-about-java-serializer-usage = off
}
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ class AttemptSysMsgRedeliveryMultiJvmSpec(artery: Boolean) extends MultiNodeConf
commonConfig(debugConfig(on = false).withFallback(
ConfigFactory.parseString(s"""
akka.remote.artery.enabled = $artery
""")).withFallback(RemotingMultiNodeSpec.arteryFlightRecordingConf))
""")).withFallback(RemotingMultiNodeSpec.commonConfig))

testTransport(on = true)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ class LookupRemoteActorMultiJvmSpec(artery: Boolean) extends MultiNodeConfig {
commonConfig(debugConfig(on = false).withFallback(
ConfigFactory.parseString(s"""
akka.remote.artery.enabled = $artery
""")).withFallback(RemotingMultiNodeSpec.arteryFlightRecordingConf))
""")).withFallback(RemotingMultiNodeSpec.commonConfig))

val master = role("master")
val slave = role("slave")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ class NewRemoteActorMultiJvmSpec(artery: Boolean) extends MultiNodeConfig {
ConfigFactory.parseString(s"""
akka.remote.log-remote-lifecycle-events = off
akka.remote.artery.enabled = $artery
""").withFallback(RemotingMultiNodeSpec.arteryFlightRecordingConf)))
""").withFallback(RemotingMultiNodeSpec.commonConfig)))

val master = role("master")
val slave = role("slave")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ class PiercingShouldKeepQuarantineConfig(artery: Boolean) extends MultiNodeConfi
ConfigFactory.parseString(s"""
akka.remote.retry-gate-closed-for = 0.5s
akka.remote.artery.enabled = $artery
""")).withFallback(RemotingMultiNodeSpec.arteryFlightRecordingConf))
""")).withFallback(RemotingMultiNodeSpec.commonConfig))

}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ class RemoteDeliveryConfig(artery: Boolean) extends MultiNodeConfig {
commonConfig(debugConfig(on = false).withFallback(
ConfigFactory.parseString(s"""
akka.remote.artery.enabled = $artery
""")).withFallback(RemotingMultiNodeSpec.arteryFlightRecordingConf))
""")).withFallback(RemotingMultiNodeSpec.commonConfig))
}

class RemoteDeliveryMultiJvmNode1 extends RemoteDeliverySpec(new RemoteDeliveryConfig(artery = false))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ class RemoteDeploymentDeathWatchMultiJvmSpec(artery: Boolean) extends MultiNodeC
akka.loglevel = INFO
akka.remote.log-remote-lifecycle-events = off
akka.remote.artery.enabled = $artery
""")).withFallback(RemotingMultiNodeSpec.arteryFlightRecordingConf))
""")).withFallback(RemotingMultiNodeSpec.commonConfig))

deployOn(second, """/hello.remote = "@third@" """)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ class RemoteNodeDeathWatchConfig(artery: Boolean) extends MultiNodeConfig {
## Use a tighter setting than the default, otherwise it takes 20s for DeathWatch to trigger
akka.remote.watch-failure-detector.acceptable-heartbeat-pause = 3 s
akka.remote.artery.enabled = $artery
""")).withFallback(RemotingMultiNodeSpec.arteryFlightRecordingConf))
""")).withFallback(RemotingMultiNodeSpec.commonConfig))

}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ class RemoteQuarantinePiercingConfig(artery: Boolean) extends MultiNodeConfig {
akka.loglevel = INFO
akka.remote.log-remote-lifecycle-events = INFO
akka.remote.artery.enabled = $artery
""")).withFallback(RemotingMultiNodeSpec.arteryFlightRecordingConf))
""")).withFallback(RemotingMultiNodeSpec.commonConfig))

}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ class RemoteReDeploymentConfig(artery: Boolean) extends MultiNodeConfig {
acceptable-heartbeat-pause=2.5s
}
akka.remote.artery.enabled = $artery
""")).withFallback(RemotingMultiNodeSpec.arteryFlightRecordingConf))
""")).withFallback(RemotingMultiNodeSpec.commonConfig))

testTransport(on = true)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,10 @@ import org.scalatest.{ Outcome, Suite }

object RemotingMultiNodeSpec {

def arteryFlightRecordingConf =
def commonConfig =
ConfigFactory.parseString(
s"""
akka.actor.warn-about-java-serializer-usage = off
akka.remote.artery.advanced.flight-recorder {
enabled=on
destination=target/flight-recorder-${UUID.randomUUID().toString}.afr
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ object LatencySpec extends MultiNodeConfig {
}
}
}
""")).withFallback(RemotingMultiNodeSpec.arteryFlightRecordingConf))
""")).withFallback(RemotingMultiNodeSpec.commonConfig))

final case object Reset

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ object MaxThroughputSpec extends MultiNodeConfig {
}
}
}
""")).withFallback(RemotingMultiNodeSpec.arteryFlightRecordingConf))
""")).withFallback(RemotingMultiNodeSpec.commonConfig))

case object Run
sealed trait Echo extends DeadLetterSuppression with JavaSerializable
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ object RemoteRestartedQuarantinedSpec extends MultiNodeConfig {
akka.loglevel = WARNING
akka.remote.log-remote-lifecycle-events = WARNING
akka.remote.artery.enabled = on
""")).withFallback(RemotingMultiNodeSpec.arteryFlightRecordingConf))
""")).withFallback(RemotingMultiNodeSpec.commonConfig))

class Subject extends Actor {
def receive = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ object SurviveNetworkPartitionSpec extends MultiNodeConfig {
akka.loglevel = INFO
akka.remote.artery.enabled = on
akka.remote.artery.advanced.give-up-system-message-after = 4s
""")).withFallback(RemotingMultiNodeSpec.arteryFlightRecordingConf))
""")).withFallback(RemotingMultiNodeSpec.commonConfig))

testTransport(on = true)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ class RemoteRandomConfig(artery: Boolean) extends MultiNodeConfig {
commonConfig(debugConfig(on = false).withFallback(
ConfigFactory.parseString(s"""
akka.remote.artery.enabled = $artery
""")).withFallback(RemotingMultiNodeSpec.arteryFlightRecordingConf))
""")).withFallback(RemotingMultiNodeSpec.commonConfig))

deployOnAll("""
/service-hello {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ class RemoteRoundRobinConfig(artery: Boolean) extends MultiNodeConfig {
commonConfig(debugConfig(on = false).withFallback(
ConfigFactory.parseString(s"""
akka.remote.artery.enabled = $artery
""")).withFallback(RemotingMultiNodeSpec.arteryFlightRecordingConf))
""")).withFallback(RemotingMultiNodeSpec.commonConfig))

deployOnAll("""
/service-hello {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ class RemoteScatterGatherConfig(artery: Boolean) extends MultiNodeConfig {
commonConfig(debugConfig(on = false).withFallback(
ConfigFactory.parseString(s"""
akka.remote.artery.enabled = $artery
""")).withFallback(RemotingMultiNodeSpec.arteryFlightRecordingConf))
""")).withFallback(RemotingMultiNodeSpec.commonConfig))

deployOnAll("""
/service-hello {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import akka.remote.testkit.{ MultiNodeConfig, MultiNodeSpec, STMultiNodeSpec }
import akka.remote.transport.ThrottlerTransportAdapter.Direction

object TestConductorMultiJvmSpec extends MultiNodeConfig {
commonConfig(debugConfig(on = false).withFallback(RemotingMultiNodeSpec.arteryFlightRecordingConf))
commonConfig(debugConfig(on = false).withFallback(RemotingMultiNodeSpec.commonConfig))

val master = role("master")
val slave = role("slave")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import akka.remote.RemotingMultiNodeSpec
import akka.testkit.LongRunningTest

object MultiNodeSpecMultiJvmSpec extends MultiNodeConfig {
commonConfig(debugConfig(on = false).withFallback(RemotingMultiNodeSpec.arteryFlightRecordingConf))
commonConfig(debugConfig(on = false).withFallback(RemotingMultiNodeSpec.commonConfig))

val node1 = role("node1")
val node2 = role("node2")
Expand Down
1 change: 1 addition & 0 deletions akka-remote/src/test/resources/reference.conf
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,6 @@ akka {
actor {
serialize-creators = on
serialize-messages = on
warn-about-java-serializer-usage = off
}
}

0 comments on commit 2679be5

Please sign in to comment.