From abf2e20cb777cdc82ba5df600252bc55f0e4683a Mon Sep 17 00:00:00 2001 From: Adrien Piquerez Date: Mon, 12 Feb 2024 16:08:14 +0100 Subject: [PATCH] Migrate to Pekko --- build.sbt | 42 +++++++++---------- .../src/main/scala/scaladex/data/Main.scala | 2 +- .../infra/GithubClientImplTests.scala | 2 +- .../scaladex/infra/CommonAkkaHttpClient.scala | 24 +++++------ .../scaladex/infra/GithubClientImpl.scala | 36 ++++++++-------- .../scaladex/infra/SonatypeClientImpl.scala | 20 ++++----- .../infra/SonatypeClientImplTests.scala | 2 +- .../src/it/scala/scaladex/RelevanceTest.scala | 4 +- .../scaladex/server/GithubAuthImpl.scala | 16 +++---- .../main/scala/scaladex/server/Server.scala | 10 ++--- .../scala/scaladex/server/TwirlSupport.scala | 8 ++-- .../scaladex/server/config/ServerConfig.scala | 2 +- .../scaladex/server/route/AdminPage.scala | 8 ++-- .../scaladex/server/route/ArtifactPages.scala | 8 ++-- .../scala/scaladex/server/route/Assets.scala | 4 +- .../server/route/AuthenticationApi.scala | 34 +++++++-------- .../scaladex/server/route/AwesomePages.scala | 8 ++-- .../scala/scaladex/server/route/Badges.scala | 14 +++---- .../scaladex/server/route/FrontPage.scala | 4 +- .../scaladex/server/route/ProjectPages.scala | 8 ++-- .../scaladex/server/route/SearchPages.scala | 6 +-- .../server/route/api/ArtifactApi.scala | 9 ++-- .../route/api/DocumentationRoutes.scala | 6 +-- .../server/route/api/OldSearchApi.scala | 8 ++-- .../server/route/api/PlayJsonSupport.scala | 18 ++++---- .../server/route/api/PublishApi.scala | 12 +++--- .../scaladex/server/route/api/SearchApi.scala | 6 +-- .../scala/scaladex/server/route/package.scala | 12 +++--- .../server/service/AdminService.scala | 2 +- .../server/service/JobScheduler.scala | 4 +- .../server/service/PublishProcess.scala | 2 +- .../server/service/UserSessionService.scala | 4 +- .../scaladex/server/route/AssetsTests.scala | 4 +- .../scaladex/server/route/BadgesTests.scala | 8 ++-- .../server/route/ControllerBaseSuite.scala | 2 +- .../server/route/ProjectPagesTests.scala | 12 +++--- .../server/route/api/ArtifactApiTests.scala | 4 +- .../route/api/DocumentationRoutesTests.scala | 2 +- .../server/route/api/PublishApiTests.scala | 10 ++--- .../scala/scaladex/view/html/package.scala | 4 +- .../twirl/scaladex/view/paginate.scala.html | 2 +- .../scaladex/view/search/result.scala.html | 2 +- .../view/search/searchresult.scala.html | 2 +- 43 files changed, 199 insertions(+), 198 deletions(-) diff --git a/build.sbt b/build.sbt index 4fef0e63a..6c50ca374 100644 --- a/build.sbt +++ b/build.sbt @@ -51,7 +51,7 @@ lazy val template = project libraryDependencies ++= Seq( "com.github.nscala-time" %% "nscala-time" % V.nscalaTime, "com.typesafe" % "config" % "1.4.3", - "com.typesafe.akka" %% "akka-http-core" % V.akkaHttp, + "org.apache.pekko" %% "pekko-http-core" % V.pekkoHttp, "org.scalatest" %% "scalatest" % V.scalatest % Test ) ) @@ -67,9 +67,9 @@ lazy val infra = project libraryDependencies ++= Seq( "com.sksamuel.elastic4s" %% "elastic4s-client-esjava" % V.elastic4s, "org.flywaydb" % "flyway-core" % "8.5.13", // for database migration - "com.typesafe.akka" %% "akka-stream" % V.akka, - "com.typesafe.akka" %% "akka-http" % V.akkaHttp, - "de.heikoseeberger" %% "akka-http-circe" % "1.39.2", + "org.apache.pekko" %% "pekko-stream" % V.pekko, + "org.apache.pekko" %% "pekko-http" % V.pekkoHttp, + "com.github.pjfanning" %% "pekko-http-circe" % "2.3.4", "io.get-coursier" %% "coursier" % V.coursier, "io.get-coursier" %% "coursier-sbt-maven-repository" % V.coursier, "org.tpolecat" %% "doobie-scalatest" % V.doobie % Test, @@ -161,16 +161,16 @@ lazy val server = project "org.scala-lang.modules" %% "scala-parallel-collections" % "1.0.4", "com.typesafe.play" %%% "play-json" % V.playJson, "org.scalatest" %% "scalatest" % V.scalatest % "test,it", - "com.typesafe.akka" %% "akka-testkit" % V.akka % "test,it", - "com.typesafe.akka" %% "akka-slf4j" % V.akka, - "com.typesafe.akka" %% "akka-serialization-jackson" % V.akka, - "com.typesafe.akka" %% "akka-actor-typed" % V.akka, - "com.typesafe.akka" %% "akka-stream-testkit" % V.akka % Test, - "com.typesafe.akka" %% "akka-http-testkit" % V.akkaHttp % Test, - "ch.megard" %% "akka-http-cors" % "1.2.0", - "com.softwaremill.akka-http-session" %% "core" % "0.7.1", - "com.typesafe.akka" %% "akka-http" % V.akkaHttp, - "org.endpoints4s" %% "akka-http-server" % "7.2.0", + "org.apache.pekko" %% "pekko-testkit" % V.pekko % "test,it", + "org.apache.pekko" %% "pekko-slf4j" % V.pekko, + "org.apache.pekko" %% "pekko-serialization-jackson" % V.pekko, + "org.apache.pekko" %% "pekko-actor-typed" % V.pekko, + "org.apache.pekko" %% "pekko-stream-testkit" % V.pekko % Test, + "org.apache.pekko" %% "pekko-http-testkit" % V.pekkoHttp % Test, + "org.apache.pekko" %% "pekko-http-cors" % V.pekkoHttp, + "com.softwaremill.pekko-http-session" %% "core" % "0.7.1", + "org.apache.pekko" %% "pekko-http" % V.pekkoHttp, + "org.endpoints4s" %% "pekko-http-server" % "1.0.1", "org.webjars" % "bootstrap-sass" % "3.4.1", "org.webjars" % "bootstrap-switch" % "3.3.4", "org.webjars" % "bootstrap-select" % "1.13.18", @@ -221,14 +221,14 @@ lazy val data = project loggingSettings, libraryDependencies ++= Seq( "com.github.nscala-time" %% "nscala-time" % V.nscalaTime, - "com.typesafe.akka" %% "akka-stream" % V.akka, - "com.typesafe.akka" %% "akka-actor-typed" % V.akka, - "com.typesafe.akka" %% "akka-serialization-jackson" % V.akka, - "com.typesafe.akka" %% "akka-slf4j" % V.akka, + "org.apache.pekko" %% "pekko-stream" % V.pekko, + "org.apache.pekko" %% "pekko-actor-typed" % V.pekko, + "org.apache.pekko" %% "pekko-serialization-jackson" % V.pekko, + "org.apache.pekko" %% "pekko-slf4j" % V.pekko, "org.apache.maven" % "maven-model-builder" % "3.9.5", "org.jsoup" % "jsoup" % "1.17.2", "org.apache.ivy" % "ivy" % "2.5.2", - "com.typesafe.akka" %% "akka-http" % V.akkaHttp, + "org.apache.pekko" %% "pekko-http" % V.pekkoHttp, "org.json4s" %% "json4s-native" % V.json4s, "org.scalatest" %% "scalatest" % V.scalatest % Test ), @@ -242,8 +242,8 @@ lazy val data = project lazy val V = new { val doobie = "0.13.4" val playJson = "2.9.4" - val akka = "2.6.18" - val akkaHttp = "10.2.10" + val pekko = "1.0.2" + val pekkoHttp = "1.0.1" val elastic4s = "8.11.5" val nscalaTime = "2.32.0" val scalatest = "3.2.17" diff --git a/modules/data/src/main/scala/scaladex/data/Main.scala b/modules/data/src/main/scala/scaladex/data/Main.scala index 68956c416..0dab7bd99 100644 --- a/modules/data/src/main/scala/scaladex/data/Main.scala +++ b/modules/data/src/main/scala/scaladex/data/Main.scala @@ -6,7 +6,7 @@ import scala.concurrent.ExecutionContext import scala.concurrent.Future import scala.sys.process.Process -import akka.actor.ActorSystem +import org.apache.pekko.actor.ActorSystem import cats.effect._ import com.typesafe.scalalogging.LazyLogging import doobie.hikari._ diff --git a/modules/infra/src/it/scala/scaladex/infra/GithubClientImplTests.scala b/modules/infra/src/it/scala/scaladex/infra/GithubClientImplTests.scala index a79c9178b..34ae555db 100644 --- a/modules/infra/src/it/scala/scaladex/infra/GithubClientImplTests.scala +++ b/modules/infra/src/it/scala/scaladex/infra/GithubClientImplTests.scala @@ -1,6 +1,6 @@ package scaladex.infra -import akka.actor.ActorSystem +import org.apache.pekko.actor.ActorSystem import org.scalatest.funspec.AsyncFunSpec import org.scalatest.matchers.should.Matchers import scaladex.core.model.Project diff --git a/modules/infra/src/main/scala/scaladex/infra/CommonAkkaHttpClient.scala b/modules/infra/src/main/scala/scaladex/infra/CommonAkkaHttpClient.scala index 3a4dc7318..a53ece196 100644 --- a/modules/infra/src/main/scala/scaladex/infra/CommonAkkaHttpClient.scala +++ b/modules/infra/src/main/scala/scaladex/infra/CommonAkkaHttpClient.scala @@ -7,18 +7,18 @@ import scala.util.Failure import scala.util.Success import scala.util.Try -import akka.actor.ActorSystem -import akka.http.scaladsl.Http -import akka.http.scaladsl.model.HttpRequest -import akka.http.scaladsl.model.HttpResponse -import akka.stream.OverflowStrategy -import akka.stream.QueueOfferResult -import akka.stream.scaladsl.Flow -import akka.stream.scaladsl.Keep -import akka.stream.scaladsl.Sink -import akka.stream.scaladsl.Source -import akka.stream.scaladsl.SourceQueueWithComplete -import de.heikoseeberger.akkahttpcirce.FailFastCirceSupport +import org.apache.pekko.actor.ActorSystem +import org.apache.pekko.http.scaladsl.Http +import org.apache.pekko.http.scaladsl.model.HttpRequest +import org.apache.pekko.http.scaladsl.model.HttpResponse +import org.apache.pekko.stream.OverflowStrategy +import org.apache.pekko.stream.QueueOfferResult +import org.apache.pekko.stream.scaladsl.Flow +import org.apache.pekko.stream.scaladsl.Keep +import org.apache.pekko.stream.scaladsl.Sink +import org.apache.pekko.stream.scaladsl.Source +import org.apache.pekko.stream.scaladsl.SourceQueueWithComplete +import com.github.pjfanning.pekkohttpcirce.FailFastCirceSupport abstract class CommonAkkaHttpClient(implicit system: ActorSystem) extends FailFastCirceSupport { diff --git a/modules/infra/src/main/scala/scaladex/infra/GithubClientImpl.scala b/modules/infra/src/main/scala/scaladex/infra/GithubClientImpl.scala index caf26b0e6..4090aae6b 100644 --- a/modules/infra/src/main/scala/scaladex/infra/GithubClientImpl.scala +++ b/modules/infra/src/main/scala/scaladex/infra/GithubClientImpl.scala @@ -6,24 +6,24 @@ import scala.concurrent.Promise import scala.concurrent.duration.DurationInt import scala.util.Try -import akka.actor.ActorSystem -import akka.http.scaladsl.Http -import akka.http.scaladsl.model.ContentTypes -import akka.http.scaladsl.model.HttpEntity -import akka.http.scaladsl.model.HttpHeader -import akka.http.scaladsl.model.HttpMethods -import akka.http.scaladsl.model.HttpRequest -import akka.http.scaladsl.model.HttpResponse -import akka.http.scaladsl.model.ResponseEntity -import akka.http.scaladsl.model.StatusCodes -import akka.http.scaladsl.model.Uri -import akka.http.scaladsl.model.headers.Authorization -import akka.http.scaladsl.model.headers.OAuth2BearerToken -import akka.http.scaladsl.model.headers.RawHeader -import akka.http.scaladsl.settings.ConnectionPoolSettings -import akka.http.scaladsl.unmarshalling.Unmarshal -import akka.stream.scaladsl.Flow -import akka.util.ByteString +import org.apache.pekko.actor.ActorSystem +import org.apache.pekko.http.scaladsl.Http +import org.apache.pekko.http.scaladsl.model.ContentTypes +import org.apache.pekko.http.scaladsl.model.HttpEntity +import org.apache.pekko.http.scaladsl.model.HttpHeader +import org.apache.pekko.http.scaladsl.model.HttpMethods +import org.apache.pekko.http.scaladsl.model.HttpRequest +import org.apache.pekko.http.scaladsl.model.HttpResponse +import org.apache.pekko.http.scaladsl.model.ResponseEntity +import org.apache.pekko.http.scaladsl.model.StatusCodes +import org.apache.pekko.http.scaladsl.model.Uri +import org.apache.pekko.http.scaladsl.model.headers.Authorization +import org.apache.pekko.http.scaladsl.model.headers.OAuth2BearerToken +import org.apache.pekko.http.scaladsl.model.headers.RawHeader +import org.apache.pekko.http.scaladsl.settings.ConnectionPoolSettings +import org.apache.pekko.http.scaladsl.unmarshalling.Unmarshal +import org.apache.pekko.stream.scaladsl.Flow +import org.apache.pekko.util.ByteString import cats.implicits.toTraverseOps import com.typesafe.scalalogging.LazyLogging import io.circe.Json diff --git a/modules/infra/src/main/scala/scaladex/infra/SonatypeClientImpl.scala b/modules/infra/src/main/scala/scaladex/infra/SonatypeClientImpl.scala index df15771f1..cd8ed7015 100644 --- a/modules/infra/src/main/scala/scaladex/infra/SonatypeClientImpl.scala +++ b/modules/infra/src/main/scala/scaladex/infra/SonatypeClientImpl.scala @@ -10,16 +10,16 @@ import scala.concurrent.Promise import scala.util.Try import scala.util.control.NonFatal -import akka.actor.ActorSystem -import akka.http.scaladsl.Http -import akka.http.scaladsl.model -import akka.http.scaladsl.model.HttpRequest -import akka.http.scaladsl.model.HttpResponse -import akka.http.scaladsl.model.StatusCodes -import akka.http.scaladsl.settings.ConnectionPoolSettings -import akka.http.scaladsl.unmarshalling.Unmarshaller -import akka.stream.scaladsl.Flow -import akka.util.ByteString +import org.apache.pekko.actor.ActorSystem +import org.apache.pekko.http.scaladsl.Http +import org.apache.pekko.http.scaladsl.model +import org.apache.pekko.http.scaladsl.model.HttpRequest +import org.apache.pekko.http.scaladsl.model.HttpResponse +import org.apache.pekko.http.scaladsl.model.StatusCodes +import org.apache.pekko.http.scaladsl.settings.ConnectionPoolSettings +import org.apache.pekko.http.scaladsl.unmarshalling.Unmarshaller +import org.apache.pekko.stream.scaladsl.Flow +import org.apache.pekko.util.ByteString import com.typesafe.scalalogging.LazyLogging import scaladex.core.model.Artifact import scaladex.core.model.Artifact.MavenReference diff --git a/modules/infra/src/test/scala/scaladex/infra/SonatypeClientImplTests.scala b/modules/infra/src/test/scala/scaladex/infra/SonatypeClientImplTests.scala index 1e696cf9d..df4b90386 100644 --- a/modules/infra/src/test/scala/scaladex/infra/SonatypeClientImplTests.scala +++ b/modules/infra/src/test/scala/scaladex/infra/SonatypeClientImplTests.scala @@ -2,7 +2,7 @@ package scaladex.infra import java.time.Instant -import akka.actor.ActorSystem +import org.apache.pekko.actor.ActorSystem import org.scalatest.funspec.AsyncFunSpec import org.scalatest.matchers.should.Matchers import scaladex.core.model.Artifact diff --git a/modules/server/src/it/scala/scaladex/RelevanceTest.scala b/modules/server/src/it/scala/scaladex/RelevanceTest.scala index 63f5131ce..4c87ab9ee 100644 --- a/modules/server/src/it/scala/scaladex/RelevanceTest.scala +++ b/modules/server/src/it/scala/scaladex/RelevanceTest.scala @@ -1,8 +1,8 @@ package scaladex import scala.concurrent.Future -import akka.actor.ActorSystem -import akka.testkit.TestKit +import org.apache.pekko.actor.ActorSystem +import org.apache.pekko.testkit.TestKit import org.scalatest.Assertion import org.scalatest.BeforeAndAfterAll import org.scalatest.funsuite.AsyncFunSuiteLike diff --git a/modules/server/src/main/scala/scaladex/server/GithubAuthImpl.scala b/modules/server/src/main/scala/scaladex/server/GithubAuthImpl.scala index 309125095..028855d83 100644 --- a/modules/server/src/main/scala/scaladex/server/GithubAuthImpl.scala +++ b/modules/server/src/main/scala/scaladex/server/GithubAuthImpl.scala @@ -3,15 +3,15 @@ package scaladex.server import scala.collection.concurrent.TrieMap import scala.concurrent.Future -import akka.actor.ActorSystem -import akka.http.scaladsl._ -import akka.http.scaladsl.model.HttpMethods.POST -import akka.http.scaladsl.model.Uri._ -import akka.http.scaladsl.model._ -import akka.http.scaladsl.model.headers._ -import akka.http.scaladsl.unmarshalling.Unmarshal +import org.apache.pekko.actor.ActorSystem +import org.apache.pekko.http.scaladsl._ +import org.apache.pekko.http.scaladsl.model.HttpMethods.POST +import org.apache.pekko.http.scaladsl.model.Uri._ +import org.apache.pekko.http.scaladsl.model._ +import org.apache.pekko.http.scaladsl.model.headers._ +import org.apache.pekko.http.scaladsl.unmarshalling.Unmarshal import com.typesafe.scalalogging.LazyLogging -import de.heikoseeberger.akkahttpcirce.FailFastCirceSupport +import com.github.pjfanning.pekkohttpcirce.FailFastCirceSupport import io.circe.Json import scaladex.core.model.GithubResponse import scaladex.core.model.UserInfo diff --git a/modules/server/src/main/scala/scaladex/server/Server.scala b/modules/server/src/main/scala/scaladex/server/Server.scala index a8f3c94a4..8e8e101f8 100644 --- a/modules/server/src/main/scala/scaladex/server/Server.scala +++ b/modules/server/src/main/scala/scaladex/server/Server.scala @@ -5,11 +5,11 @@ import scala.util.Failure import scala.util.Success import scala.util.control.NonFatal -import akka.actor.ActorSystem -import akka.http.scaladsl._ -import akka.http.scaladsl.model.StatusCodes -import akka.http.scaladsl.server.Directives._ -import akka.http.scaladsl.server._ +import org.apache.pekko.actor.ActorSystem +import org.apache.pekko.http.scaladsl._ +import org.apache.pekko.http.scaladsl.model.StatusCodes +import org.apache.pekko.http.scaladsl.server.Directives._ +import org.apache.pekko.http.scaladsl.server._ import cats.effect.ContextShift import cats.effect.IO import com.typesafe.scalalogging.LazyLogging diff --git a/modules/server/src/main/scala/scaladex/server/TwirlSupport.scala b/modules/server/src/main/scala/scaladex/server/TwirlSupport.scala index ca28e9c7a..3210f1401 100644 --- a/modules/server/src/main/scala/scaladex/server/TwirlSupport.scala +++ b/modules/server/src/main/scala/scaladex/server/TwirlSupport.scala @@ -2,10 +2,10 @@ package scaladex.server // https://github.com/btomala/akka-http-twirl -import akka.http.scaladsl.marshalling.Marshaller -import akka.http.scaladsl.marshalling.ToEntityMarshaller -import akka.http.scaladsl.model.MediaType -import akka.http.scaladsl.model.MediaTypes._ +import org.apache.pekko.http.scaladsl.marshalling.Marshaller +import org.apache.pekko.http.scaladsl.marshalling.ToEntityMarshaller +import org.apache.pekko.http.scaladsl.model.MediaType +import org.apache.pekko.http.scaladsl.model.MediaTypes._ import play.twirl.api.Html import play.twirl.api.Txt import play.twirl.api.Xml diff --git a/modules/server/src/main/scala/scaladex/server/config/ServerConfig.scala b/modules/server/src/main/scala/scaladex/server/config/ServerConfig.scala index 4a269b4e5..c6915dd47 100644 --- a/modules/server/src/main/scala/scaladex/server/config/ServerConfig.scala +++ b/modules/server/src/main/scala/scaladex/server/config/ServerConfig.scala @@ -1,6 +1,6 @@ package scaladex.server.config -import com.softwaremill.session.SessionConfig +import com.softwaremill.pekkohttpsession.SessionConfig import com.typesafe.config.Config import com.typesafe.config.ConfigFactory import scaladex.core.model.Env diff --git a/modules/server/src/main/scala/scaladex/server/route/AdminPage.scala b/modules/server/src/main/scala/scaladex/server/route/AdminPage.scala index 33767cac0..eefbc786e 100644 --- a/modules/server/src/main/scala/scaladex/server/route/AdminPage.scala +++ b/modules/server/src/main/scala/scaladex/server/route/AdminPage.scala @@ -1,8 +1,8 @@ package scaladex.server.route -import akka.http.scaladsl.model.StatusCodes -import akka.http.scaladsl.model.Uri -import akka.http.scaladsl.server.Directives._ -import akka.http.scaladsl.server.Route +import org.apache.pekko.http.scaladsl.model.StatusCodes +import org.apache.pekko.http.scaladsl.model.Uri +import org.apache.pekko.http.scaladsl.server.Directives._ +import org.apache.pekko.http.scaladsl.server.Route import scaladex.core.model.Artifact import scaladex.core.model.Env import scaladex.core.model.Project diff --git a/modules/server/src/main/scala/scaladex/server/route/ArtifactPages.scala b/modules/server/src/main/scala/scaladex/server/route/ArtifactPages.scala index a2c268806..6b81b7ec0 100644 --- a/modules/server/src/main/scala/scaladex/server/route/ArtifactPages.scala +++ b/modules/server/src/main/scala/scaladex/server/route/ArtifactPages.scala @@ -3,10 +3,10 @@ package scaladex.server.route import scala.concurrent.ExecutionContext import scala.util.Success -import akka.http.scaladsl.model.StatusCodes -import akka.http.scaladsl.model._ -import akka.http.scaladsl.server.Directives._ -import akka.http.scaladsl.server.Route +import org.apache.pekko.http.scaladsl.model.StatusCodes +import org.apache.pekko.http.scaladsl.model._ +import org.apache.pekko.http.scaladsl.server.Directives._ +import org.apache.pekko.http.scaladsl.server.Route import com.typesafe.scalalogging.LazyLogging import scaladex.core.model.Env import scaladex.core.model.UserState diff --git a/modules/server/src/main/scala/scaladex/server/route/Assets.scala b/modules/server/src/main/scala/scaladex/server/route/Assets.scala index e09ba8633..91789021e 100644 --- a/modules/server/src/main/scala/scaladex/server/route/Assets.scala +++ b/modules/server/src/main/scala/scaladex/server/route/Assets.scala @@ -1,7 +1,7 @@ package scaladex.server.route -import akka.http.scaladsl.server.Directives._ -import akka.http.scaladsl.server.Route +import org.apache.pekko.http.scaladsl.server.Directives._ +import org.apache.pekko.http.scaladsl.server.Route object Assets { val routes: Route = diff --git a/modules/server/src/main/scala/scaladex/server/route/AuthenticationApi.scala b/modules/server/src/main/scala/scaladex/server/route/AuthenticationApi.scala index 64ae2b736..852a4a756 100644 --- a/modules/server/src/main/scala/scaladex/server/route/AuthenticationApi.scala +++ b/modules/server/src/main/scala/scaladex/server/route/AuthenticationApi.scala @@ -5,23 +5,23 @@ import java.util.UUID import scala.util.Success import scala.util.Try -import akka.actor.ActorSystem -import akka.http.scaladsl.model.StatusCodes.TemporaryRedirect -import akka.http.scaladsl.model.Uri.Query -import akka.http.scaladsl.model._ -import akka.http.scaladsl.model.headers.Referer -import akka.http.scaladsl.server.Directive1 -import akka.http.scaladsl.server.Directives._ -import akka.http.scaladsl.server.Route -import com.softwaremill.session.CsrfDirectives._ -import com.softwaremill.session.CsrfOptions._ -import com.softwaremill.session.SessionConfig -import com.softwaremill.session.SessionDirectives._ -import com.softwaremill.session.SessionManager -import com.softwaremill.session.SessionOptions._ -import com.softwaremill.session.SessionSerializer -import com.softwaremill.session.SingleValueSessionSerializer -import com.softwaremill.session.javadsl.InMemoryRefreshTokenStorage +import org.apache.pekko.actor.ActorSystem +import org.apache.pekko.http.scaladsl.model.StatusCodes.TemporaryRedirect +import org.apache.pekko.http.scaladsl.model.Uri.Query +import org.apache.pekko.http.scaladsl.model._ +import org.apache.pekko.http.scaladsl.model.headers.Referer +import org.apache.pekko.http.scaladsl.server.Directive1 +import org.apache.pekko.http.scaladsl.server.Directives._ +import org.apache.pekko.http.scaladsl.server.Route +import com.softwaremill.pekkohttpsession.CsrfDirectives._ +import com.softwaremill.pekkohttpsession.CsrfOptions._ +import com.softwaremill.pekkohttpsession.SessionConfig +import com.softwaremill.pekkohttpsession.SessionDirectives._ +import com.softwaremill.pekkohttpsession.SessionManager +import com.softwaremill.pekkohttpsession.SessionOptions._ +import com.softwaremill.pekkohttpsession.SessionSerializer +import com.softwaremill.pekkohttpsession.SingleValueSessionSerializer +import com.softwaremill.pekkohttpsession.javadsl.InMemoryRefreshTokenStorage import com.typesafe.scalalogging.LazyLogging import scaladex.core.model.UserState import scaladex.core.service.GithubAuth diff --git a/modules/server/src/main/scala/scaladex/server/route/AwesomePages.scala b/modules/server/src/main/scala/scaladex/server/route/AwesomePages.scala index b3acf5264..5a948026a 100644 --- a/modules/server/src/main/scala/scaladex/server/route/AwesomePages.scala +++ b/modules/server/src/main/scala/scaladex/server/route/AwesomePages.scala @@ -3,10 +3,10 @@ package scaladex.server.route import scala.concurrent.ExecutionContext import scala.concurrent.Future -import akka.http.scaladsl.server.Directive1 -import akka.http.scaladsl.server.Directives._ -import akka.http.scaladsl.server.PathMatcher1 -import akka.http.scaladsl.server.Route +import org.apache.pekko.http.scaladsl.server.Directive1 +import org.apache.pekko.http.scaladsl.server.Directives._ +import org.apache.pekko.http.scaladsl.server.PathMatcher1 +import org.apache.pekko.http.scaladsl.server.Route import play.twirl.api.Html import scaladex.core.model.Category import scaladex.core.model.Env diff --git a/modules/server/src/main/scala/scaladex/server/route/Badges.scala b/modules/server/src/main/scala/scaladex/server/route/Badges.scala index b1126f132..ac0beef2d 100644 --- a/modules/server/src/main/scala/scaladex/server/route/Badges.scala +++ b/modules/server/src/main/scala/scaladex/server/route/Badges.scala @@ -3,13 +3,13 @@ package scaladex.server.route import scala.concurrent.ExecutionContext import scala.concurrent.Future -import akka.http.scaladsl.model.StatusCodes._ -import akka.http.scaladsl.model.headers.CacheDirectives._ -import akka.http.scaladsl.model.headers._ -import akka.http.scaladsl.server.Directives._ -import akka.http.scaladsl.server.RequestContext -import akka.http.scaladsl.server.Route -import akka.http.scaladsl.server.RouteResult +import org.apache.pekko.http.scaladsl.model.StatusCodes._ +import org.apache.pekko.http.scaladsl.model.headers.CacheDirectives._ +import org.apache.pekko.http.scaladsl.model.headers._ +import org.apache.pekko.http.scaladsl.server.Directives._ +import org.apache.pekko.http.scaladsl.server.RequestContext +import org.apache.pekko.http.scaladsl.server.Route +import org.apache.pekko.http.scaladsl.server.RouteResult import scaladex.core.model.Artifact import scaladex.core.model.ArtifactSelection import scaladex.core.model.BinaryVersion diff --git a/modules/server/src/main/scala/scaladex/server/route/FrontPage.scala b/modules/server/src/main/scala/scaladex/server/route/FrontPage.scala index c7b3cb5eb..a2cac3663 100644 --- a/modules/server/src/main/scala/scaladex/server/route/FrontPage.scala +++ b/modules/server/src/main/scala/scaladex/server/route/FrontPage.scala @@ -3,8 +3,8 @@ package scaladex.server.route import scala.concurrent.ExecutionContext import scala.concurrent.Future -import akka.http.scaladsl.server.Directives._ -import akka.http.scaladsl.server.Route +import org.apache.pekko.http.scaladsl.server.Directives._ +import org.apache.pekko.http.scaladsl.server.Route import play.twirl.api.HtmlFormat import scaladex.core.model._ import scaladex.core.service.SearchEngine diff --git a/modules/server/src/main/scala/scaladex/server/route/ProjectPages.scala b/modules/server/src/main/scala/scaladex/server/route/ProjectPages.scala index c84df1d2d..f4a8adf19 100644 --- a/modules/server/src/main/scala/scaladex/server/route/ProjectPages.scala +++ b/modules/server/src/main/scala/scaladex/server/route/ProjectPages.scala @@ -9,10 +9,10 @@ import scala.concurrent.Future import scala.util.Failure import scala.util.Success -import akka.http.scaladsl.model.Uri._ -import akka.http.scaladsl.model._ -import akka.http.scaladsl.server.Directives._ -import akka.http.scaladsl.server._ +import org.apache.pekko.http.scaladsl.model.Uri._ +import org.apache.pekko.http.scaladsl.model._ +import org.apache.pekko.http.scaladsl.server.Directives._ +import org.apache.pekko.http.scaladsl.server._ import com.typesafe.scalalogging.LazyLogging import scaladex.core.model._ import scaladex.core.service.SearchEngine diff --git a/modules/server/src/main/scala/scaladex/server/route/SearchPages.scala b/modules/server/src/main/scala/scaladex/server/route/SearchPages.scala index cfa91acc6..25b8dcc98 100644 --- a/modules/server/src/main/scala/scaladex/server/route/SearchPages.scala +++ b/modules/server/src/main/scala/scaladex/server/route/SearchPages.scala @@ -2,9 +2,9 @@ package scaladex.server.route import scala.concurrent.ExecutionContext -import akka.http.scaladsl.model.Uri._ -import akka.http.scaladsl.server.Directives._ -import akka.http.scaladsl.server._ +import org.apache.pekko.http.scaladsl.model.Uri._ +import org.apache.pekko.http.scaladsl.server.Directives._ +import org.apache.pekko.http.scaladsl.server._ import scaladex.core.model.Env import scaladex.core.model.UserState import scaladex.core.model.search.Page diff --git a/modules/server/src/main/scala/scaladex/server/route/api/ArtifactApi.scala b/modules/server/src/main/scala/scaladex/server/route/api/ArtifactApi.scala index 98dd55689..aa5a9ff48 100644 --- a/modules/server/src/main/scala/scaladex/server/route/api/ArtifactApi.scala +++ b/modules/server/src/main/scala/scaladex/server/route/api/ArtifactApi.scala @@ -3,10 +3,10 @@ package scaladex.server.route.api import scala.concurrent.ExecutionContext import scala.concurrent.Future -import akka.http.scaladsl.server.Directives._ -import akka.http.scaladsl.server.Route -import ch.megard.akka.http.cors.scaladsl.CorsDirectives.cors -import endpoints4s.akkahttp.server +import org.apache.pekko.http.scaladsl.server.Directives._ +import org.apache.pekko.http.scaladsl.server.Route +import org.apache.pekko.http.cors.scaladsl.CorsDirectives.cors +import endpoints4s.pekkohttp.server import scaladex.core.api.artifact.ArtifactEndpoints import scaladex.core.api.artifact.ArtifactMetadataParams import scaladex.core.api.artifact.ArtifactMetadataResponse @@ -19,6 +19,7 @@ import scaladex.core.model.search.Page import scaladex.core.model.search.Pagination import scaladex.core.service.WebDatabase + class ArtifactApi(database: WebDatabase)( implicit ec: ExecutionContext ) extends ArtifactEndpoints diff --git a/modules/server/src/main/scala/scaladex/server/route/api/DocumentationRoutes.scala b/modules/server/src/main/scala/scaladex/server/route/api/DocumentationRoutes.scala index ce142406f..8934f0959 100644 --- a/modules/server/src/main/scala/scaladex/server/route/api/DocumentationRoutes.scala +++ b/modules/server/src/main/scala/scaladex/server/route/api/DocumentationRoutes.scala @@ -1,8 +1,8 @@ package scaladex.server.route.api -import akka.http.scaladsl.server.Route -import ch.megard.akka.http.cors.scaladsl.CorsDirectives.cors -import endpoints4s.akkahttp.server +import org.apache.pekko.http.scaladsl.server.Route +import org.apache.pekko.http.cors.scaladsl.CorsDirectives.cors +import endpoints4s.pekkohttp.server import endpoints4s.openapi.model.OpenApi /** diff --git a/modules/server/src/main/scala/scaladex/server/route/api/OldSearchApi.scala b/modules/server/src/main/scala/scaladex/server/route/api/OldSearchApi.scala index 1e71bcd40..daacf2b57 100644 --- a/modules/server/src/main/scala/scaladex/server/route/api/OldSearchApi.scala +++ b/modules/server/src/main/scala/scaladex/server/route/api/OldSearchApi.scala @@ -3,10 +3,10 @@ package scaladex.server.route.api import scala.concurrent.ExecutionContext import scala.concurrent.Future -import akka.http.scaladsl.model.StatusCodes._ -import akka.http.scaladsl.server.Directives._ -import akka.http.scaladsl.server.Route -import ch.megard.akka.http.cors.scaladsl.CorsDirectives._ +import org.apache.pekko.http.scaladsl.model.StatusCodes._ +import org.apache.pekko.http.scaladsl.server.Directives._ +import org.apache.pekko.http.scaladsl.server.Route +import org.apache.pekko.http.cors.scaladsl.CorsDirectives._ import play.api.libs.json._ import scaladex.core.model.Artifact import scaladex.core.model.ArtifactSelection diff --git a/modules/server/src/main/scala/scaladex/server/route/api/PlayJsonSupport.scala b/modules/server/src/main/scala/scaladex/server/route/api/PlayJsonSupport.scala index 8d172d845..eae0ddd51 100644 --- a/modules/server/src/main/scala/scaladex/server/route/api/PlayJsonSupport.scala +++ b/modules/server/src/main/scala/scaladex/server/route/api/PlayJsonSupport.scala @@ -18,15 +18,15 @@ package scaladex.server.route.api import scala.collection.immutable.Seq -import akka.http.scaladsl.marshalling.Marshaller -import akka.http.scaladsl.marshalling.ToEntityMarshaller -import akka.http.scaladsl.model.ContentTypeRange -import akka.http.scaladsl.model.MediaTypes.`application/json` -import akka.http.scaladsl.server.RejectionError -import akka.http.scaladsl.server.ValidationRejection -import akka.http.scaladsl.unmarshalling.FromEntityUnmarshaller -import akka.http.scaladsl.unmarshalling.Unmarshaller -import akka.util.ByteString +import org.apache.pekko.http.scaladsl.marshalling.Marshaller +import org.apache.pekko.http.scaladsl.marshalling.ToEntityMarshaller +import org.apache.pekko.http.scaladsl.model.ContentTypeRange +import org.apache.pekko.http.scaladsl.model.MediaTypes.`application/json` +import org.apache.pekko.http.scaladsl.server.RejectionError +import org.apache.pekko.http.scaladsl.server.ValidationRejection +import org.apache.pekko.http.scaladsl.unmarshalling.FromEntityUnmarshaller +import org.apache.pekko.http.scaladsl.unmarshalling.Unmarshaller +import org.apache.pekko.util.ByteString import play.api.libs.json.JsError import play.api.libs.json.JsValue import play.api.libs.json.Json diff --git a/modules/server/src/main/scala/scaladex/server/route/api/PublishApi.scala b/modules/server/src/main/scala/scaladex/server/route/api/PublishApi.scala index d5a32fcca..fc4e4db08 100644 --- a/modules/server/src/main/scala/scaladex/server/route/api/PublishApi.scala +++ b/modules/server/src/main/scala/scaladex/server/route/api/PublishApi.scala @@ -5,12 +5,12 @@ import java.time.Instant import scala.collection.concurrent.TrieMap import scala.concurrent.ExecutionContext -import akka.http.scaladsl.model.StatusCodes -import akka.http.scaladsl.model.headers._ -import akka.http.scaladsl.server.AuthorizationFailedRejection -import akka.http.scaladsl.server.Directive1 -import akka.http.scaladsl.server.Directives._ -import akka.http.scaladsl.server.Route +import org.apache.pekko.http.scaladsl.model.StatusCodes +import org.apache.pekko.http.scaladsl.model.headers._ +import org.apache.pekko.http.scaladsl.server.AuthorizationFailedRejection +import org.apache.pekko.http.scaladsl.server.Directive1 +import org.apache.pekko.http.scaladsl.server.Directives._ +import org.apache.pekko.http.scaladsl.server.Route import com.typesafe.scalalogging.LazyLogging import scaladex.core.model.UserState import scaladex.core.service.GithubAuth diff --git a/modules/server/src/main/scala/scaladex/server/route/api/SearchApi.scala b/modules/server/src/main/scala/scaladex/server/route/api/SearchApi.scala index 665dc2373..e0675b739 100644 --- a/modules/server/src/main/scala/scaladex/server/route/api/SearchApi.scala +++ b/modules/server/src/main/scala/scaladex/server/route/api/SearchApi.scala @@ -2,9 +2,9 @@ package scaladex.server.route.api import scala.concurrent.ExecutionContext -import akka.http.scaladsl.server.Route -import ch.megard.akka.http.cors.scaladsl.CorsDirectives._ -import endpoints4s.akkahttp.server +import org.apache.pekko.http.scaladsl.server.Route +import org.apache.pekko.http.cors.scaladsl.CorsDirectives._ +import endpoints4s.pekkohttp.server import scaladex.core.api.AutocompletionResponse import scaladex.core.api.SearchEndpoints import scaladex.core.model.UserState diff --git a/modules/server/src/main/scala/scaladex/server/route/package.scala b/modules/server/src/main/scala/scaladex/server/route/package.scala index a042b6bc0..2e01315ab 100644 --- a/modules/server/src/main/scala/scaladex/server/route/package.scala +++ b/modules/server/src/main/scala/scaladex/server/route/package.scala @@ -2,12 +2,12 @@ package scaladex.server import java.time.Instant -import akka.http.scaladsl.server.Directive1 -import akka.http.scaladsl.server.Directives.Segment -import akka.http.scaladsl.server.Directives._ -import akka.http.scaladsl.server.PathMatcher -import akka.http.scaladsl.server.PathMatcher1 -import akka.http.scaladsl.unmarshalling.Unmarshaller +import org.apache.pekko.http.scaladsl.server.Directive1 +import org.apache.pekko.http.scaladsl.server.Directives.Segment +import org.apache.pekko.http.scaladsl.server.Directives._ +import org.apache.pekko.http.scaladsl.server.PathMatcher +import org.apache.pekko.http.scaladsl.server.PathMatcher1 +import org.apache.pekko.http.scaladsl.unmarshalling.Unmarshaller import scaladex.core.model.Artifact import scaladex.core.model.Project import scaladex.core.model.SemanticVersion diff --git a/modules/server/src/main/scala/scaladex/server/service/AdminService.scala b/modules/server/src/main/scala/scaladex/server/service/AdminService.scala index b22b7fd90..7744c7271 100644 --- a/modules/server/src/main/scala/scaladex/server/service/AdminService.scala +++ b/modules/server/src/main/scala/scaladex/server/service/AdminService.scala @@ -1,7 +1,7 @@ package scaladex.server.service import scala.concurrent.Future -import akka.actor.ActorSystem +import org.apache.pekko.actor.ActorSystem import com.typesafe.scalalogging.LazyLogging import scaladex.core.model.Artifact import scaladex.core.model.Env diff --git a/modules/server/src/main/scala/scaladex/server/service/JobScheduler.scala b/modules/server/src/main/scala/scaladex/server/service/JobScheduler.scala index 9daad7a23..161341dba 100644 --- a/modules/server/src/main/scala/scaladex/server/service/JobScheduler.scala +++ b/modules/server/src/main/scala/scaladex/server/service/JobScheduler.scala @@ -7,8 +7,8 @@ import scala.concurrent.Future import scala.concurrent.duration._ import scala.util.control.NonFatal -import akka.actor.ActorSystem -import akka.actor.Cancellable +import org.apache.pekko.actor.ActorSystem +import org.apache.pekko.actor.Cancellable import com.typesafe.scalalogging.LazyLogging import scaladex.core.model.UserState import scaladex.view.Job diff --git a/modules/server/src/main/scala/scaladex/server/service/PublishProcess.scala b/modules/server/src/main/scala/scaladex/server/service/PublishProcess.scala index 833746ca5..4ed862061 100644 --- a/modules/server/src/main/scala/scaladex/server/service/PublishProcess.scala +++ b/modules/server/src/main/scala/scaladex/server/service/PublishProcess.scala @@ -5,7 +5,7 @@ import java.time.Instant import scala.concurrent.ExecutionContext import scala.concurrent.Future -import akka.actor.ActorSystem +import org.apache.pekko.actor.ActorSystem import com.typesafe.scalalogging.LazyLogging import scaladex.core.model.Env import scaladex.core.model.Project diff --git a/modules/server/src/main/scala/scaladex/server/service/UserSessionService.scala b/modules/server/src/main/scala/scaladex/server/service/UserSessionService.scala index 4993b543b..5bd1e7cfd 100644 --- a/modules/server/src/main/scala/scaladex/server/service/UserSessionService.scala +++ b/modules/server/src/main/scala/scaladex/server/service/UserSessionService.scala @@ -4,8 +4,8 @@ import java.util.UUID import scala.concurrent.Future -import akka.actor.ActorSystem -import akka.http.scaladsl.model.StatusCodes +import org.apache.pekko.actor.ActorSystem +import org.apache.pekko.http.scaladsl.model.StatusCodes import com.typesafe.scalalogging.LazyLogging import scaladex.core.model.GithubResponse import scaladex.core.model.UserState diff --git a/modules/server/src/test/scala/scaladex/server/route/AssetsTests.scala b/modules/server/src/test/scala/scaladex/server/route/AssetsTests.scala index ecccdc6bb..c94c90d45 100644 --- a/modules/server/src/test/scala/scaladex/server/route/AssetsTests.scala +++ b/modules/server/src/test/scala/scaladex/server/route/AssetsTests.scala @@ -1,7 +1,7 @@ package scaladex.server.route -import akka.http.scaladsl.model.StatusCodes -import akka.http.scaladsl.testkit.ScalatestRouteTest +import org.apache.pekko.http.scaladsl.model.StatusCodes +import org.apache.pekko.http.scaladsl.testkit.ScalatestRouteTest import org.scalatest.funspec.AnyFunSpec import org.scalatest.matchers.should.Matchers import scaladex.server.route.Assets diff --git a/modules/server/src/test/scala/scaladex/server/route/BadgesTests.scala b/modules/server/src/test/scala/scaladex/server/route/BadgesTests.scala index 5d79e2136..cad9f8c51 100644 --- a/modules/server/src/test/scala/scaladex/server/route/BadgesTests.scala +++ b/modules/server/src/test/scala/scaladex/server/route/BadgesTests.scala @@ -4,10 +4,10 @@ import scala.concurrent.Await import scala.concurrent.Future import scala.concurrent.duration.Duration -import akka.http.scaladsl.model.StatusCodes -import akka.http.scaladsl.model.Uri -import akka.http.scaladsl.model.headers.Location -import akka.http.scaladsl.server.Route +import org.apache.pekko.http.scaladsl.model.StatusCodes +import org.apache.pekko.http.scaladsl.model.Uri +import org.apache.pekko.http.scaladsl.model.headers.Location +import org.apache.pekko.http.scaladsl.server.Route import org.scalatest.BeforeAndAfterAll import org.scalatest.funspec.AnyFunSpec import org.scalatest.matchers.should.Matchers diff --git a/modules/server/src/test/scala/scaladex/server/route/ControllerBaseSuite.scala b/modules/server/src/test/scala/scaladex/server/route/ControllerBaseSuite.scala index 92ec0841f..b0d3def66 100644 --- a/modules/server/src/test/scala/scaladex/server/route/ControllerBaseSuite.scala +++ b/modules/server/src/test/scala/scaladex/server/route/ControllerBaseSuite.scala @@ -3,7 +3,7 @@ package scaladex.server.route import java.nio.file.Files import java.nio.file.Path -import akka.http.scaladsl.testkit.ScalatestRouteTest +import org.apache.pekko.http.scaladsl.testkit.ScalatestRouteTest import org.scalatest.funspec.AsyncFunSpec import org.scalatest.matchers.should.Matchers import scaladex.core.service.SearchEngine diff --git a/modules/server/src/test/scala/scaladex/server/route/ProjectPagesTests.scala b/modules/server/src/test/scala/scaladex/server/route/ProjectPagesTests.scala index f5d1cc95f..17baa7cdc 100644 --- a/modules/server/src/test/scala/scaladex/server/route/ProjectPagesTests.scala +++ b/modules/server/src/test/scala/scaladex/server/route/ProjectPagesTests.scala @@ -4,12 +4,12 @@ import scala.concurrent.Await import scala.concurrent.Future import scala.concurrent.duration.Duration -import akka.http.scaladsl.model.FormData -import akka.http.scaladsl.model.StatusCodes -import akka.http.scaladsl.model.Uri -import akka.http.scaladsl.model.headers.Location -import akka.http.scaladsl.server.Directives._ -import akka.http.scaladsl.server.Route +import org.apache.pekko.http.scaladsl.model.FormData +import org.apache.pekko.http.scaladsl.model.StatusCodes +import org.apache.pekko.http.scaladsl.model.Uri +import org.apache.pekko.http.scaladsl.model.headers.Location +import org.apache.pekko.http.scaladsl.server.Directives._ +import org.apache.pekko.http.scaladsl.server.Route import org.scalatest.BeforeAndAfterEach import scaladex.core.model.GithubStatus import scaladex.core.model.Project diff --git a/modules/server/src/test/scala/scaladex/server/route/api/ArtifactApiTests.scala b/modules/server/src/test/scala/scaladex/server/route/api/ArtifactApiTests.scala index d69977eec..104d91498 100644 --- a/modules/server/src/test/scala/scaladex/server/route/api/ArtifactApiTests.scala +++ b/modules/server/src/test/scala/scaladex/server/route/api/ArtifactApiTests.scala @@ -4,8 +4,8 @@ import scala.concurrent.Await import scala.concurrent.Future import scala.concurrent.duration.Duration -import akka.http.scaladsl.model.StatusCodes -import akka.http.scaladsl.server.Route +import org.apache.pekko.http.scaladsl.model.StatusCodes +import org.apache.pekko.http.scaladsl.server.Route import cats.implicits.toTraverseOps import org.scalatest.BeforeAndAfterEach import play.api.libs.json.Reads diff --git a/modules/server/src/test/scala/scaladex/server/route/api/DocumentationRoutesTests.scala b/modules/server/src/test/scala/scaladex/server/route/api/DocumentationRoutesTests.scala index 7d3b4ac8a..e066665f5 100644 --- a/modules/server/src/test/scala/scaladex/server/route/api/DocumentationRoutesTests.scala +++ b/modules/server/src/test/scala/scaladex/server/route/api/DocumentationRoutesTests.scala @@ -1,6 +1,6 @@ package scaladex.server.route.api -import akka.http.scaladsl.model.StatusCodes +import org.apache.pekko.http.scaladsl.model.StatusCodes import play.api.libs.json.JsValue import scaladex.server.route.ControllerBaseSuite diff --git a/modules/server/src/test/scala/scaladex/server/route/api/PublishApiTests.scala b/modules/server/src/test/scala/scaladex/server/route/api/PublishApiTests.scala index a469ef384..a246c17f6 100644 --- a/modules/server/src/test/scala/scaladex/server/route/api/PublishApiTests.scala +++ b/modules/server/src/test/scala/scaladex/server/route/api/PublishApiTests.scala @@ -1,11 +1,11 @@ package scaladex.server.route.api import scala.concurrent.duration.DurationInt -import akka.http.scaladsl.model.ContentTypes -import akka.http.scaladsl.model.HttpEntity -import akka.http.scaladsl.model.StatusCodes -import akka.http.scaladsl.model.headers.BasicHttpCredentials -import akka.http.scaladsl.testkit.RouteTestTimeout +import org.apache.pekko.http.scaladsl.model.ContentTypes +import org.apache.pekko.http.scaladsl.model.HttpEntity +import org.apache.pekko.http.scaladsl.model.StatusCodes +import org.apache.pekko.http.scaladsl.model.headers.BasicHttpCredentials +import org.apache.pekko.http.scaladsl.testkit.RouteTestTimeout import org.scalatest.BeforeAndAfterEach import scaladex.core.model.Env import scaladex.core.test.MockGithubAuth diff --git a/modules/template/src/main/scala/scaladex/view/html/package.scala b/modules/template/src/main/scala/scaladex/view/html/package.scala index d6eda5e78..6c073cf16 100644 --- a/modules/template/src/main/scala/scaladex/view/html/package.scala +++ b/modules/template/src/main/scala/scaladex/view/html/package.scala @@ -5,8 +5,8 @@ import java.time.ZoneId import java.time.format.DateTimeFormatter import java.util.Locale -import akka.http.scaladsl.model.Uri -import akka.http.scaladsl.model.Uri.Query +import org.apache.pekko.http.scaladsl.model.Uri +import org.apache.pekko.http.scaladsl.model.Uri.Query import scaladex.core.model.Artifact import scaladex.core.model.BinaryVersion import scaladex.core.model.Category diff --git a/modules/template/src/main/twirl/scaladex/view/paginate.scala.html b/modules/template/src/main/twirl/scaladex/view/paginate.scala.html index 4855859e8..51a2448c1 100644 --- a/modules/template/src/main/twirl/scaladex/view/paginate.scala.html +++ b/modules/template/src/main/twirl/scaladex/view/paginate.scala.html @@ -1,4 +1,4 @@ -@import akka.http.scaladsl.model.Uri +@import org.apache.pekko.http.scaladsl.model.Uri @import scaladex.core.model.search.Pagination @(pagination: Pagination, uriFun: Int => Uri) diff --git a/modules/template/src/main/twirl/scaladex/view/search/result.scala.html b/modules/template/src/main/twirl/scaladex/view/search/result.scala.html index a2c6a2164..aebd49a00 100644 --- a/modules/template/src/main/twirl/scaladex/view/search/result.scala.html +++ b/modules/template/src/main/twirl/scaladex/view/search/result.scala.html @@ -1,4 +1,4 @@ -@import akka.http.scaladsl.model.Uri +@import org.apache.pekko.http.scaladsl.model.Uri @import scaladex.view.html._ @import scaladex.core.model.search.Pagination @import scaladex.core.model.search.SearchParams diff --git a/modules/template/src/main/twirl/scaladex/view/search/searchresult.scala.html b/modules/template/src/main/twirl/scaladex/view/search/searchresult.scala.html index 9003e7b0f..3d3e4b56b 100644 --- a/modules/template/src/main/twirl/scaladex/view/search/searchresult.scala.html +++ b/modules/template/src/main/twirl/scaladex/view/search/searchresult.scala.html @@ -1,4 +1,4 @@ -@import akka.http.scaladsl.model.Uri +@import org.apache.pekko.http.scaladsl.model.Uri @import scaladex.view.html._ @import scaladex.core.model.search.SearchParams @import scaladex.core.model.search.Pagination