From ca70c0e47e86246bb4256c4f83ad6e45e03187f0 Mon Sep 17 00:00:00 2001 From: Karel Cemus Date: Mon, 5 Feb 2024 00:25:34 +0100 Subject: [PATCH] Migration to Pekko --- .../scala/play/api/cache/redis/RedisCacheModule.scala | 2 +- .../api/cache/redis/configuration/RedisSettings.scala | 2 +- .../api/cache/redis/connector/PekkoSerializer.scala | 11 +++++------ .../api/cache/redis/connector/RedisCommands.scala | 2 +- .../redis/connector/RedisConnectorProvider.scala | 3 +-- .../api/cache/redis/connector/RequestTimeout.scala | 1 - .../scala/play/api/cache/redis/impl/Builders.scala | 2 -- .../play/api/cache/redis/impl/JavaCompatibility.scala | 3 +-- .../scala/play/api/cache/redis/impl/RedisCaches.scala | 2 -- .../play/api/cache/redis/impl/RedisRuntime.scala | 5 ++--- .../api/cache/redis/RedisCacheComponentsSpec.scala | 2 +- .../play/api/cache/redis/RedisCacheModuleSpec.scala | 3 +-- .../api/cache/redis/connector/FailEagerlySpec.scala | 2 +- .../api/cache/redis/connector/RedisClusterSpec.scala | 4 ++-- .../redis/connector/RedisConnectorFailureSpec.scala | 4 ++-- .../redis/connector/RedisRequestTimeoutSpec.scala | 3 +-- .../api/cache/redis/connector/RedisSentinelSpec.scala | 4 ++-- .../cache/redis/connector/RedisStandaloneSpec.scala | 4 ++-- .../api/cache/redis/connector/SerializerSpec.scala | 6 +++--- .../play/api/cache/redis/impl/AsyncRedisMock.scala | 1 - .../play/api/cache/redis/impl/BuildersSpec.scala | 8 -------- .../play/api/cache/redis/impl/RedisRuntimeMock.scala | 2 +- .../play/api/cache/redis/impl/RedisRuntimeSpec.scala | 4 ++-- .../scala/play/api/cache/redis/test/BaseSpec.scala | 4 ++-- .../play/api/cache/redis/test/FakeApplication.scala | 2 +- .../scala/play/api/cache/redis/test/RedisLogger.scala | 2 +- .../api/cache/redis/test/StoppableApplication.scala | 4 ++-- 27 files changed, 36 insertions(+), 56 deletions(-) diff --git a/src/main/scala/play/api/cache/redis/RedisCacheModule.scala b/src/main/scala/play/api/cache/redis/RedisCacheModule.scala index e0d1287..ac56f93 100644 --- a/src/main/scala/play/api/cache/redis/RedisCacheModule.scala +++ b/src/main/scala/play/api/cache/redis/RedisCacheModule.scala @@ -24,7 +24,7 @@ class RedisCacheModule extends Module { // common settings val commons = Seq( // bind serializer - bind[connector.PekkoSerializer].toProvider[connector.AkkaSerializerProvider], + bind[connector.PekkoSerializer].toProvider[connector.PekkoSerializerProvider], bind[configuration.RedisInstanceResolver].to[GuiceRedisInstanceResolver], ) // bind recovery resolver diff --git a/src/main/scala/play/api/cache/redis/configuration/RedisSettings.scala b/src/main/scala/play/api/cache/redis/configuration/RedisSettings.scala index 60b3ac1..be60898 100644 --- a/src/main/scala/play/api/cache/redis/configuration/RedisSettings.scala +++ b/src/main/scala/play/api/cache/redis/configuration/RedisSettings.scala @@ -5,7 +5,7 @@ import play.api.ConfigLoader /** * Configures non-connection related settings of redis instance, e.g., - * synchronization timeout, Akka dispatcher, and recovery policy. + * synchronization timeout, Pekko dispatcher, and recovery policy. */ trait RedisSettings { diff --git a/src/main/scala/play/api/cache/redis/connector/PekkoSerializer.scala b/src/main/scala/play/api/cache/redis/connector/PekkoSerializer.scala index 5ee5555..54c7c70 100644 --- a/src/main/scala/play/api/cache/redis/connector/PekkoSerializer.scala +++ b/src/main/scala/play/api/cache/redis/connector/PekkoSerializer.scala @@ -1,9 +1,8 @@ package play.api.cache.redis.connector -import play.api.cache.redis._ - import org.apache.pekko.actor.ActorSystem import org.apache.pekko.serialization.{Serialization, SerializationExtension} +import play.api.cache.redis._ import java.util.Base64 import javax.inject._ @@ -45,10 +44,10 @@ trait PekkoSerializer { } /** - * Pekko encoder provides implementation of serialization using Pekko serializer. - * The implementation considers all primitives, nulls, and refs. This enables - * us to use Pekko settings to modify serializer mapping and use different - * serializers for different objects. + * Pekko encoder provides implementation of serialization using Pekko + * serializer. The implementation considers all primitives, nulls, and refs. + * This enables us to use Pekko settings to modify serializer mapping and use + * different serializers for different objects. */ private[connector] class PekkoEncoder(serializer: Serialization) { diff --git a/src/main/scala/play/api/cache/redis/connector/RedisCommands.scala b/src/main/scala/play/api/cache/redis/connector/RedisCommands.scala index 4a025f3..c90b33b 100644 --- a/src/main/scala/play/api/cache/redis/connector/RedisCommands.scala +++ b/src/main/scala/play/api/cache/redis/connector/RedisCommands.scala @@ -1,6 +1,6 @@ package play.api.cache.redis.connector -import org.apache.pekko.actor.ActorSystem +import org.apache.pekko.actor.{ActorSystem, Scheduler} import play.api.Logger import play.api.cache.redis.configuration._ import play.api.inject.ApplicationLifecycle diff --git a/src/main/scala/play/api/cache/redis/connector/RedisConnectorProvider.scala b/src/main/scala/play/api/cache/redis/connector/RedisConnectorProvider.scala index 8d83497..c548544 100644 --- a/src/main/scala/play/api/cache/redis/connector/RedisConnectorProvider.scala +++ b/src/main/scala/play/api/cache/redis/connector/RedisConnectorProvider.scala @@ -1,14 +1,13 @@ package play.api.cache.redis.connector import org.apache.pekko.actor.ActorSystem - import play.api.cache.redis._ import play.api.inject.ApplicationLifecycle import javax.inject.Provider /** Provides an instance of named redis connector */ -private[redis] class RedisConnectorProvider(instance: RedisInstance, serializer: AkkaSerializer)(implicit system: ActorSystem, lifecycle: ApplicationLifecycle, runtime: RedisRuntime) extends Provider[RedisConnector] { +private[redis] class RedisConnectorProvider(instance: RedisInstance, serializer: PekkoSerializer)(implicit system: ActorSystem, lifecycle: ApplicationLifecycle, runtime: RedisRuntime) extends Provider[RedisConnector] { private[connector] lazy val commands = new RedisCommandsProvider(instance).get diff --git a/src/main/scala/play/api/cache/redis/connector/RequestTimeout.scala b/src/main/scala/play/api/cache/redis/connector/RequestTimeout.scala index a7c256e..85aaf2c 100644 --- a/src/main/scala/play/api/cache/redis/connector/RequestTimeout.scala +++ b/src/main/scala/play/api/cache/redis/connector/RequestTimeout.scala @@ -1,6 +1,5 @@ package play.api.cache.redis.connector - import org.apache.pekko.actor.Scheduler import org.apache.pekko.pattern.after import redis._ diff --git a/src/main/scala/play/api/cache/redis/impl/Builders.scala b/src/main/scala/play/api/cache/redis/impl/Builders.scala index 7ea66a4..f1a0dac 100644 --- a/src/main/scala/play/api/cache/redis/impl/Builders.scala +++ b/src/main/scala/play/api/cache/redis/impl/Builders.scala @@ -1,7 +1,5 @@ package play.api.cache.redis.impl -import org.apache.pekko.pattern.AskTimeoutException - import scala.concurrent.Future /** diff --git a/src/main/scala/play/api/cache/redis/impl/JavaCompatibility.scala b/src/main/scala/play/api/cache/redis/impl/JavaCompatibility.scala index f635733..5a3c9dc 100644 --- a/src/main/scala/play/api/cache/redis/impl/JavaCompatibility.scala +++ b/src/main/scala/play/api/cache/redis/impl/JavaCompatibility.scala @@ -1,10 +1,9 @@ package play.api.cache.redis.impl +import org.apache.pekko.Done import play.api.Environment import play.api.cache.redis._ -import org.apache.pekko.Done - import scala.concurrent.{ExecutionContext, Future} import scala.reflect.ClassTag diff --git a/src/main/scala/play/api/cache/redis/impl/RedisCaches.scala b/src/main/scala/play/api/cache/redis/impl/RedisCaches.scala index 11ec427..de225f0 100644 --- a/src/main/scala/play/api/cache/redis/impl/RedisCaches.scala +++ b/src/main/scala/play/api/cache/redis/impl/RedisCaches.scala @@ -1,8 +1,6 @@ package play.api.cache.redis.impl import org.apache.pekko.actor.ActorSystem - -import javax.inject.Provider import play.api.Environment import play.api.cache.redis._ import play.api.inject.ApplicationLifecycle diff --git a/src/main/scala/play/api/cache/redis/impl/RedisRuntime.scala b/src/main/scala/play/api/cache/redis/impl/RedisRuntime.scala index 0761b5b..2c76c39 100644 --- a/src/main/scala/play/api/cache/redis/impl/RedisRuntime.scala +++ b/src/main/scala/play/api/cache/redis/impl/RedisRuntime.scala @@ -1,8 +1,7 @@ package play.api.cache.redis.impl -import play.api.cache.redis._ - import org.apache.pekko.actor.ActorSystem +import play.api.cache.redis._ import scala.concurrent.ExecutionContext import scala.concurrent.duration.FiniteDuration @@ -24,7 +23,7 @@ final private[redis] case class RedisRuntimeImpl( policy: RecoveryPolicy, invocation: InvocationPolicy, prefix: RedisPrefix, - timeout: org.apache.pekko.util.Timeout + timeout: org.apache.pekko.util.Timeout, ) extends RedisRuntime private[redis] object RedisRuntime { diff --git a/src/test/scala/play/api/cache/redis/RedisCacheComponentsSpec.scala b/src/test/scala/play/api/cache/redis/RedisCacheComponentsSpec.scala index b59c36d..f662aeb 100644 --- a/src/test/scala/play/api/cache/redis/RedisCacheComponentsSpec.scala +++ b/src/test/scala/play/api/cache/redis/RedisCacheComponentsSpec.scala @@ -1,6 +1,6 @@ package play.api.cache.redis -import akka.actor.ActorSystem +import org.apache.pekko.actor.ActorSystem import play.api._ import play.api.cache.redis.test._ import play.api.inject.ApplicationLifecycle diff --git a/src/test/scala/play/api/cache/redis/RedisCacheModuleSpec.scala b/src/test/scala/play/api/cache/redis/RedisCacheModuleSpec.scala index df91a80..dc4fbd1 100644 --- a/src/test/scala/play/api/cache/redis/RedisCacheModuleSpec.scala +++ b/src/test/scala/play/api/cache/redis/RedisCacheModuleSpec.scala @@ -1,6 +1,5 @@ package play.api.cache.redis - import org.apache.pekko.actor.ActorSystem import play.api.cache.redis.configuration.{RedisHost, RedisSettings, RedisStandalone, RedisTimeouts} import play.api.cache.redis.test._ @@ -134,7 +133,7 @@ class RedisCacheModuleSpec extends IntegrationSpec with RedisStandaloneContainer password = None, ), settings = RedisSettings( - dispatcher = "akka.actor.default-dispatcher", + dispatcher = "pekko.actor.default-dispatcher", invocationPolicy = "lazy", timeout = RedisTimeouts(1.second), recovery = "log-and-default", diff --git a/src/test/scala/play/api/cache/redis/connector/FailEagerlySpec.scala b/src/test/scala/play/api/cache/redis/connector/FailEagerlySpec.scala index 427a1a4..fe68c2c 100644 --- a/src/test/scala/play/api/cache/redis/connector/FailEagerlySpec.scala +++ b/src/test/scala/play/api/cache/redis/connector/FailEagerlySpec.scala @@ -1,6 +1,6 @@ package play.api.cache.redis.connector -import org.apache.pekko.actor.ActorSystem +import org.apache.pekko.actor.{ActorSystem, Scheduler} import play.api.cache.redis.test._ import scala.concurrent.duration._ diff --git a/src/test/scala/play/api/cache/redis/connector/RedisClusterSpec.scala b/src/test/scala/play/api/cache/redis/connector/RedisClusterSpec.scala index a298c54..0dcf121 100644 --- a/src/test/scala/play/api/cache/redis/connector/RedisClusterSpec.scala +++ b/src/test/scala/play/api/cache/redis/connector/RedisClusterSpec.scala @@ -1,6 +1,6 @@ package play.api.cache.redis.connector -import akka.actor.ActorSystem +import org.apache.pekko.actor.ActorSystem import play.api.cache.redis._ import play.api.cache.redis.configuration._ import play.api.cache.redis.impl._ @@ -78,7 +78,7 @@ class RedisClusterSpec extends IntegrationSpec with RedisClusterContainer { implicit val system: ActorSystem = ActorSystem("test", classLoader = Some(getClass.getClassLoader)) implicit val runtime: RedisRuntime = RedisRuntime("cluster", syncTimeout = 5.seconds, ExecutionContext.global, new LogAndFailPolicy, LazyInvocation) implicit val application: StoppableApplication = StoppableApplication(system) - val serializer = new AkkaSerializerImpl(system) + val serializer = new PekkoSerializerImpl(system) application.runAsyncInApplication { for { diff --git a/src/test/scala/play/api/cache/redis/connector/RedisConnectorFailureSpec.scala b/src/test/scala/play/api/cache/redis/connector/RedisConnectorFailureSpec.scala index 681a476..466d95e 100644 --- a/src/test/scala/play/api/cache/redis/connector/RedisConnectorFailureSpec.scala +++ b/src/test/scala/play/api/cache/redis/connector/RedisConnectorFailureSpec.scala @@ -244,7 +244,7 @@ class RedisConnectorFailureSpec extends AsyncUnitSpec with ImplicitFutureMateria private def test(name: String)(f: (SerializerAssertions, RedisCommandsMock, RedisConnector) => Future[Assertion]): Unit = name in { implicit val runtime: RedisRuntime = mock[RedisRuntime] - val serializer = mock[AkkaSerializer] + val serializer = mock[PekkoSerializer] val commands = mock[RedisCommandsMock] val connector: RedisConnector = new RedisConnectorImpl(serializer, commands) @@ -253,7 +253,7 @@ class RedisConnectorFailureSpec extends AsyncUnitSpec with ImplicitFutureMateria f(new SerializerAssertions(serializer), commands, connector) } - private class SerializerAssertions(mock: AkkaSerializer) { + private class SerializerAssertions(mock: PekkoSerializer) { def failOnEncode[T](value: T): Future[Unit] = Future.successful { diff --git a/src/test/scala/play/api/cache/redis/connector/RedisRequestTimeoutSpec.scala b/src/test/scala/play/api/cache/redis/connector/RedisRequestTimeoutSpec.scala index 9a862f7..b8053a9 100644 --- a/src/test/scala/play/api/cache/redis/connector/RedisRequestTimeoutSpec.scala +++ b/src/test/scala/play/api/cache/redis/connector/RedisRequestTimeoutSpec.scala @@ -1,7 +1,6 @@ package play.api.cache.redis.connector - -import org.apache.pekko.actor.ActorSystem +import org.apache.pekko.actor.{ActorSystem, Scheduler} import play.api.cache.redis.test.{AsyncUnitSpec, StoppableApplication} import redis.RedisCommand import redis.protocol.RedisReply diff --git a/src/test/scala/play/api/cache/redis/connector/RedisSentinelSpec.scala b/src/test/scala/play/api/cache/redis/connector/RedisSentinelSpec.scala index ae0bfb8..de89fee 100644 --- a/src/test/scala/play/api/cache/redis/connector/RedisSentinelSpec.scala +++ b/src/test/scala/play/api/cache/redis/connector/RedisSentinelSpec.scala @@ -1,6 +1,6 @@ package play.api.cache.redis.connector -import akka.actor.ActorSystem +import org.apache.pekko.actor.ActorSystem import org.scalatest.Ignore import play.api.cache.redis._ import play.api.cache.redis.configuration._ @@ -66,7 +66,7 @@ class RedisSentinelSpec extends IntegrationSpec with RedisSentinelContainer { implicit val system: ActorSystem = ActorSystem("test", classLoader = Some(getClass.getClassLoader)) implicit val runtime: RedisRuntime = RedisRuntime("sentinel", syncTimeout = 5.seconds, ExecutionContext.global, new LogAndFailPolicy, LazyInvocation) implicit val application: StoppableApplication = StoppableApplication(system) - val serializer = new AkkaSerializerImpl(system) + val serializer = new PekkoSerializerImpl(system) lazy val sentinelInstance = RedisSentinel( name = "sentinel", diff --git a/src/test/scala/play/api/cache/redis/connector/RedisStandaloneSpec.scala b/src/test/scala/play/api/cache/redis/connector/RedisStandaloneSpec.scala index 2321fd7..690fb0c 100644 --- a/src/test/scala/play/api/cache/redis/connector/RedisStandaloneSpec.scala +++ b/src/test/scala/play/api/cache/redis/connector/RedisStandaloneSpec.scala @@ -1,6 +1,6 @@ package play.api.cache.redis.connector -import akka.actor.ActorSystem +import org.apache.pekko.actor.ActorSystem import play.api.cache.redis._ import play.api.cache.redis.configuration._ import play.api.cache.redis.impl._ @@ -587,7 +587,7 @@ class RedisStandaloneSpec extends IntegrationSpec with RedisStandaloneContainer implicit val system: ActorSystem = ActorSystem("test", classLoader = Some(getClass.getClassLoader)) implicit val runtime: RedisRuntime = RedisRuntime("standalone", syncTimeout = 5.seconds, ExecutionContext.global, new LogAndFailPolicy, LazyInvocation) implicit val application: StoppableApplication = StoppableApplication(system) - val serializer = new AkkaSerializerImpl(system) + val serializer = new PekkoSerializerImpl(system) lazy val instance = RedisStandalone( name = "play", diff --git a/src/test/scala/play/api/cache/redis/connector/SerializerSpec.scala b/src/test/scala/play/api/cache/redis/connector/SerializerSpec.scala index b841238..58ae80e 100644 --- a/src/test/scala/play/api/cache/redis/connector/SerializerSpec.scala +++ b/src/test/scala/play/api/cache/redis/connector/SerializerSpec.scala @@ -1,6 +1,6 @@ package play.api.cache.redis.connector -import akka.actor.ActorSystem +import org.apache.pekko.actor.ActorSystem import play.api.cache.redis._ import play.api.cache.redis.test._ @@ -171,10 +171,10 @@ class SerializerSpec extends AsyncUnitSpec { } } - private def test(name: String)(f: AkkaSerializer => Unit): Unit = + private def test(name: String)(f: PekkoSerializer => Unit): Unit = name in { val system = ActorSystem.apply(s"test-${Random.nextInt()}", classLoader = Some(getClass.getClassLoader)) - val serializer: AkkaSerializer = new AkkaSerializerImpl(system) + val serializer: PekkoSerializer = new PekkoSerializerImpl(system) f(serializer) system.terminate().map(_ => Passed) } diff --git a/src/test/scala/play/api/cache/redis/impl/AsyncRedisMock.scala b/src/test/scala/play/api/cache/redis/impl/AsyncRedisMock.scala index 6365e88..ae66047 100644 --- a/src/test/scala/play/api/cache/redis/impl/AsyncRedisMock.scala +++ b/src/test/scala/play/api/cache/redis/impl/AsyncRedisMock.scala @@ -1,6 +1,5 @@ package play.api.cache.redis.impl -import akka.Done import org.scalamock.scalatest.AsyncMockFactoryBase import play.api.cache.redis._ diff --git a/src/test/scala/play/api/cache/redis/impl/BuildersSpec.scala b/src/test/scala/play/api/cache/redis/impl/BuildersSpec.scala index f626a56..44b6e3d 100644 --- a/src/test/scala/play/api/cache/redis/impl/BuildersSpec.scala +++ b/src/test/scala/play/api/cache/redis/impl/BuildersSpec.scala @@ -1,7 +1,5 @@ package play.api.cache.redis.impl - -import org.apache.pekko.pattern.AskTimeoutException import play.api.cache.redis._ import play.api.cache.redis.test._ @@ -107,12 +105,6 @@ class BuildersSpec extends AsyncUnitSpec with RedisRuntimeMock { SynchronousBuilder.toResult(Task.infinite(), Task.resolved()) mustEqual Task.resolved.response } - "recover from peko ask timeout" in new RuntimeMock { - runtime.policy returns failThrough - val actorFailure = Future.failed(new AskTimeoutException("Simulated actor ask timeout")) - SynchronousBuilder.toResult(actorFailure, Task.resolved()) mustEqual Task.resolved.response - } - "map value" in { implicit val runtime: RedisRuntime = redisRuntime() SynchronousBuilder.map(5)(_ + 5) mustEqual 10 diff --git a/src/test/scala/play/api/cache/redis/impl/RedisRuntimeMock.scala b/src/test/scala/play/api/cache/redis/impl/RedisRuntimeMock.scala index 4f44ac3..e9f33b8 100644 --- a/src/test/scala/play/api/cache/redis/impl/RedisRuntimeMock.scala +++ b/src/test/scala/play/api/cache/redis/impl/RedisRuntimeMock.scala @@ -1,6 +1,6 @@ package play.api.cache.redis.impl -import akka.util.Timeout +import org.apache.pekko.util.Timeout import org.scalamock.scalatest.AsyncMockFactoryBase import play.api.cache.redis.{FailThrough, RecoverWithDefault, RecoveryPolicy, RedisException} diff --git a/src/test/scala/play/api/cache/redis/impl/RedisRuntimeSpec.scala b/src/test/scala/play/api/cache/redis/impl/RedisRuntimeSpec.scala index d0a6c91..abcfc9f 100644 --- a/src/test/scala/play/api/cache/redis/impl/RedisRuntimeSpec.scala +++ b/src/test/scala/play/api/cache/redis/impl/RedisRuntimeSpec.scala @@ -1,7 +1,7 @@ package play.api.cache.redis.impl -import akka.actor.ActorSystem -import org.apache.pekko.util..util.Timeout +import org.apache.pekko.actor.ActorSystem +import org.apache.pekko.util.Timeout import play.api.cache.redis._ import play.api.cache.redis.configuration.{RedisHost, RedisStandalone} import play.api.cache.redis.test.UnitSpec diff --git a/src/test/scala/play/api/cache/redis/test/BaseSpec.scala b/src/test/scala/play/api/cache/redis/test/BaseSpec.scala index 00d7e18..cac81cb 100644 --- a/src/test/scala/play/api/cache/redis/test/BaseSpec.scala +++ b/src/test/scala/play/api/cache/redis/test/BaseSpec.scala @@ -1,6 +1,6 @@ package play.api.cache.redis.test -import akka.Done +import org.apache.pekko.Done import org.scalactic.source.Position import org.scalamock.scalatest.AsyncMockFactory import org.scalatest._ @@ -23,7 +23,7 @@ trait DefaultValues { val defaultsSettings: RedisSettingsTest = RedisSettingsTest( - invocationContext = "akka.actor.default-dispatcher", + invocationContext = "pekko.actor.default-dispatcher", invocationPolicy = "lazy", timeout = RedisTimeouts(1.second, None, Some(500.millis)), recovery = "log-and-default", diff --git a/src/test/scala/play/api/cache/redis/test/FakeApplication.scala b/src/test/scala/play/api/cache/redis/test/FakeApplication.scala index 7836ce7..d00c6be 100644 --- a/src/test/scala/play/api/cache/redis/test/FakeApplication.scala +++ b/src/test/scala/play/api/cache/redis/test/FakeApplication.scala @@ -1,6 +1,6 @@ package play.api.cache.redis.test -import akka.actor.ActorSystem +import org.apache.pekko.actor.ActorSystem import play.api.inject.Injector trait FakeApplication extends StoppableApplication { diff --git a/src/test/scala/play/api/cache/redis/test/RedisLogger.scala b/src/test/scala/play/api/cache/redis/test/RedisLogger.scala index d786811..c980583 100644 --- a/src/test/scala/play/api/cache/redis/test/RedisLogger.scala +++ b/src/test/scala/play/api/cache/redis/test/RedisLogger.scala @@ -5,7 +5,7 @@ import org.apache.pekko.event.slf4j.Slf4jLogger /** * This logger fixes initialization issues; it fixes race conditions between - * Akka and Slf4j, this ensures that Slf4j is initialized first. + * Pekko and Slf4j, this ensures that Slf4j is initialized first. */ class RedisLogger extends Slf4jLogger { diff --git a/src/test/scala/play/api/cache/redis/test/StoppableApplication.scala b/src/test/scala/play/api/cache/redis/test/StoppableApplication.scala index 5fbd2f5..827ad81 100644 --- a/src/test/scala/play/api/cache/redis/test/StoppableApplication.scala +++ b/src/test/scala/play/api/cache/redis/test/StoppableApplication.scala @@ -1,7 +1,7 @@ package play.api.cache.redis.test -import akka.Done -import akka.actor.{ActorSystem, CoordinatedShutdown} +import org.apache.pekko.Done +import org.apache.pekko.actor.{ActorSystem, CoordinatedShutdown} import org.scalatest.Assertion import play.api.inject.ApplicationLifecycle