You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pekko.apache.org by he...@apache.org on 2024/03/21 08:02:38 UTC

(incubator-pekko) branch main updated: chore: Remove default parameter of AbruptStreamTerminationException (#1212)

This is an automated email from the ASF dual-hosted git repository.

hepin pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/incubator-pekko.git


The following commit(s) were added to refs/heads/main by this push:
     new 4bb851db12 chore: Remove default parameter of AbruptStreamTerminationException (#1212)
4bb851db12 is described below

commit 4bb851db120b40fd33b445addd4b1f2c21004497
Author: He-Pin(kerr) <he...@gmail.com>
AuthorDate: Thu Mar 21 16:02:32 2024 +0800

    chore: Remove default parameter of AbruptStreamTerminationException (#1212)
---
 .../src/main/scala/org/apache/pekko/stream/ActorMaterializer.scala | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/stream/src/main/scala/org/apache/pekko/stream/ActorMaterializer.scala b/stream/src/main/scala/org/apache/pekko/stream/ActorMaterializer.scala
index b692c3d313..02f6ff4751 100644
--- a/stream/src/main/scala/org/apache/pekko/stream/ActorMaterializer.scala
+++ b/stream/src/main/scala/org/apache/pekko/stream/ActorMaterializer.scala
@@ -270,7 +270,7 @@ class MaterializationException(msg: String, cause: Throwable = null) extends Run
 /**
  * A base exception for abrupt stream termination.
  */
-sealed class AbruptStreamTerminationException(msg: String, cause: Throwable = null)
+sealed class AbruptStreamTerminationException(msg: String, cause: Throwable)
     extends RuntimeException(msg, cause)
     with NoStackTrace
 
@@ -280,7 +280,7 @@ sealed class AbruptStreamTerminationException(msg: String, cause: Throwable = nu
  * when an ActorSystem is shut down while stream processing actors are still running.
  */
 final case class AbruptTerminationException(actor: ActorRef)
-    extends AbruptStreamTerminationException(s"Processor actor [$actor] terminated abruptly")
+    extends AbruptStreamTerminationException(s"Processor actor [$actor] terminated abruptly", cause = null)
 
 /**
  * Signal that the operator was abruptly terminated, usually seen as a call to `postStop` of the `GraphStageLogic` without
@@ -289,7 +289,8 @@ final case class AbruptTerminationException(actor: ActorRef)
  */
 final class AbruptStageTerminationException(logic: GraphStageLogic)
     extends AbruptStreamTerminationException(
-      s"GraphStage [$logic] terminated abruptly, caused by for example materializer or actor system termination.")
+      s"GraphStage [$logic] terminated abruptly, caused by for example materializer or actor system termination.",
+      cause = null)
 
 object ActorMaterializerSettings {
 


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pekko.apache.org
For additional commands, e-mail: commits-help@pekko.apache.org