This is an automated email from the ASF dual-hosted git repository. nvollmar pushed a commit to branch fix-unhandled-shardsupdated in repository https://gitbox.apache.org/repos/asf/pekko.git
commit 79ea277b029527a115fdd8b27aaeab6366c671c8 Author: Nicolas Vollmar <[email protected]> AuthorDate: Fri May 24 13:44:25 2024 +0200 Avoid unnecessary shard updates while shutting down --- .../src/main/scala/org/apache/pekko/cluster/sharding/ShardRegion.scala | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cluster-sharding/src/main/scala/org/apache/pekko/cluster/sharding/ShardRegion.scala b/cluster-sharding/src/main/scala/org/apache/pekko/cluster/sharding/ShardRegion.scala index 169f71d464..250719eada 100644 --- a/cluster-sharding/src/main/scala/org/apache/pekko/cluster/sharding/ShardRegion.scala +++ b/cluster-sharding/src/main/scala/org/apache/pekko/cluster/sharding/ShardRegion.scala @@ -1003,7 +1003,7 @@ private[pekko] class ShardRegion( shardsByRef = shardsByRef - ref shards = shards - shardId startingShards -= shardId - if (settings.passivationStrategy != ClusterShardingSettings.NoPassivationStrategy) { + if (settings.passivationStrategy != ClusterShardingSettings.NoPassivationStrategy && !gracefulShutdownInProgress) { shards.values.foreach(_ ! ShardsUpdated(shards.size)) } if (handingOff.contains(ref)) { --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
