Skip to content

Commit d641441

Browse files
committed
upversion to akka http 10.2.0
1 parent dd7104e commit d641441

File tree

3 files changed

+3
-8
lines changed

3 files changed

+3
-8
lines changed

gateway/src/main/scala/talos/gateway/EndpointResolver.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ object EndpointResolver {
1111

1212
def transformRequest(request: HttpRequest, hitEndpoint: HitEndpoint): IO[HttpRequest] = IO {
1313
request
14-
.copy(uri = request.uri.withHost(hitEndpoint.service).withPath(Path(hitEndpoint.targetPath))
14+
.withUri(uri = request.uri.withHost(hitEndpoint.service).withPath(Path(hitEndpoint.targetPath))
1515
.withPort(hitEndpoint.port)).withHeaders(request.headers.filterNot(_.name == "Timeout-Access"))
1616
}
1717

gateway/src/main/scala/talos/gateway/ExecutionApi.scala

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ object ExecutionApi {
6666

6767

6868
private def hostConnectionPoolConfig(maxInflightRequests: Int)(implicit actorSystem: ActorSystem[_]): ConnectionPoolSettings =
69-
ConnectionPoolSettings.default(actorSystem.toClassic)
69+
ConnectionPoolSettings.default(actorSystem)
7070
.withMinConnections(1 + maxInflightRequests / 4)
7171
.withMaxConnections(maxInflightRequests)
7272
.withMaxOpenRequests(maxInflightRequests * 4)
@@ -90,8 +90,6 @@ object ExecutionApi {
9090
val fromServices = gatewayConfig.services.map {
9191
service =>
9292

93-
implicit val classicSystem = actorSystem.toClassic
94-
9593
val poolClientFlow = Http().cachedHostConnectionPool[Promise[HttpResponse]](
9694
service.host,
9795
service.port,

gateway/src/main/scala/talos/gateway/GatewayServer.scala

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
package talos.gateway
22

33
import akka.actor.typed.scaladsl.ActorContext
4-
import akka.actor.typed.scaladsl.adapter._
54
import akka.http.scaladsl.Http
6-
import akka.stream.Materializer
75
import kamon.Kamon
86
import talos.gateway.config.GatewayConfig
97

@@ -15,10 +13,9 @@ class GatewayServer private(gatewayConfig: GatewayConfig)(implicit actorContext:
1513

1614
private[gateway] val start: Future[Http.ServerBinding] = {
1715
val gateway = Gateway(gatewayConfig)(actorContext)
18-
implicit val materializer = Materializer(actorContext)
1916
import scala.concurrent.ExecutionContext.Implicits._
2017

21-
implicit val actorSystem = actorContext.system.toClassic
18+
implicit val actorSystem = actorContext.system
2219

2320
for {
2421
serverBinding <- Http().newServerAt(gatewayConfig.interface, gatewayConfig.port).bind(gateway.route)

0 commit comments

Comments
 (0)