From 994a0c4de3301ccc8878d1c28c72758e5aa3e019 Mon Sep 17 00:00:00 2001 From: PJ Fanning Date: Sun, 17 Aug 2025 20:59:59 +0100 Subject: [PATCH 1/2] remove use of ActorMaterializer --- .../pekko/http/impl/util/StageLoggingWithOverride.scala | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/http-core/src/main/scala/org/apache/pekko/http/impl/util/StageLoggingWithOverride.scala b/http-core/src/main/scala/org/apache/pekko/http/impl/util/StageLoggingWithOverride.scala index c7ace934a..10e26b4fc 100644 --- a/http-core/src/main/scala/org/apache/pekko/http/impl/util/StageLoggingWithOverride.scala +++ b/http-core/src/main/scala/org/apache/pekko/http/impl/util/StageLoggingWithOverride.scala @@ -20,7 +20,7 @@ import org.apache.pekko import pekko.annotation.InternalApi import pekko.stream.stage.GraphStageLogic import pekko.event.{ LogSource, LoggingAdapter, NoLogging } -import pekko.stream.ActorMaterializer +import pekko.stream.Materializer // TODO Try to reconcile with what Pekko provides in StageLogging. // We thought this could be removed when https://github.com/akka/akka/issues/18793 had been implemented @@ -44,8 +44,8 @@ private[pekko] trait StageLoggingWithOverride extends GraphStageLogic { logOverride match { case DefaultNoLogging => materializer match { - case a: ActorMaterializer => pekko.event.Logging(a.system, logSource)(LogSource.fromClass) - case _ => NoLogging + case m: Materializer => pekko.event.Logging(m.system, logSource)(LogSource.fromClass) + case _ => NoLogging } case x => x } From 7b26725ecf6ae3d11510fb5fb91d88080dd37e8d Mon Sep 17 00:00:00 2001 From: PJ Fanning Date: Sun, 17 Aug 2025 22:05:36 +0100 Subject: [PATCH 2/2] Update StageLoggingWithOverride.scala --- .../pekko/http/impl/util/StageLoggingWithOverride.scala | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/http-core/src/main/scala/org/apache/pekko/http/impl/util/StageLoggingWithOverride.scala b/http-core/src/main/scala/org/apache/pekko/http/impl/util/StageLoggingWithOverride.scala index 10e26b4fc..dd6592eb0 100644 --- a/http-core/src/main/scala/org/apache/pekko/http/impl/util/StageLoggingWithOverride.scala +++ b/http-core/src/main/scala/org/apache/pekko/http/impl/util/StageLoggingWithOverride.scala @@ -19,8 +19,7 @@ package org.apache.pekko.http.impl.util import org.apache.pekko import pekko.annotation.InternalApi import pekko.stream.stage.GraphStageLogic -import pekko.event.{ LogSource, LoggingAdapter, NoLogging } -import pekko.stream.Materializer +import pekko.event.{ LogSource, LoggingAdapter } // TODO Try to reconcile with what Pekko provides in StageLogging. // We thought this could be removed when https://github.com/akka/akka/issues/18793 had been implemented @@ -43,10 +42,7 @@ private[pekko] trait StageLoggingWithOverride extends GraphStageLogic { _log = logOverride match { case DefaultNoLogging => - materializer match { - case m: Materializer => pekko.event.Logging(m.system, logSource)(LogSource.fromClass) - case _ => NoLogging - } + pekko.event.Logging(materializer.system, logSource)(LogSource.fromClass) case x => x } case _ =>