зеркало из https://github.com/akkadotnet/akka.net.git
Cluster.Join fails when called asynchronically when SerializeAllMessages is set (#4488)
* Serializer failed to serialize CurrentClusterState when SerializeAllMessages was set. * Serializer failed to serialize CurrentClusterState when SerializeAllMessages was set. * Use defensive coding to prevent exception from being thrown from duplicate key insertion (#4489) * Revert serialization to prefer INoSerializationVerificationNeeded instead. * Update API approval list Co-authored-by: Aaron Stannard <aaron@petabridge.com>
This commit is contained in:
Родитель
c42a309065
Коммит
5c19ec833b
|
@ -68,7 +68,7 @@ namespace Akka.Cluster
|
|||
public static readonly Akka.Cluster.ClusterEvent.IClusterDomainEvent Instance;
|
||||
public override string ToString() { }
|
||||
}
|
||||
public sealed class CurrentClusterState
|
||||
public sealed class CurrentClusterState : Akka.Actor.INoSerializationVerificationNeeded
|
||||
{
|
||||
public CurrentClusterState() { }
|
||||
public CurrentClusterState(System.Collections.Immutable.ImmutableSortedSet<Akka.Cluster.Member> members, System.Collections.Immutable.ImmutableHashSet<Akka.Cluster.Member> unreachable, System.Collections.Immutable.ImmutableHashSet<Akka.Actor.Address> seenBy, Akka.Actor.Address leader, System.Collections.Immutable.ImmutableDictionary<string, Akka.Actor.Address> roleLeaderMap) { }
|
||||
|
|
|
@ -35,6 +35,7 @@ namespace Akka.Cluster.Tests
|
|||
publish-stats-interval = 0 s # always, when it happens
|
||||
run-coordinated-shutdown-when-down = off
|
||||
}
|
||||
akka.actor.serialize-messages = on
|
||||
akka.actor.provider = ""Akka.Cluster.ClusterActorRefProvider, Akka.Cluster""
|
||||
akka.coordinated-shutdown.terminate-actor-system = off
|
||||
akka.coordinated-shutdown.run-by-actor-system-terminate = off
|
||||
|
|
|
@ -14,6 +14,7 @@ using Akka.Actor;
|
|||
using Akka.Dispatch;
|
||||
using Akka.Event;
|
||||
using Akka.Util.Internal;
|
||||
using Newtonsoft.Json;
|
||||
|
||||
namespace Akka.Cluster
|
||||
{
|
||||
|
@ -67,7 +68,7 @@ namespace Akka.Cluster
|
|||
/// <summary>
|
||||
/// A snapshot of the current state of the <see cref="Cluster"/>
|
||||
/// </summary>
|
||||
public sealed class CurrentClusterState
|
||||
public sealed class CurrentClusterState : INoSerializationVerificationNeeded
|
||||
{
|
||||
private readonly ImmutableSortedSet<Member> _members;
|
||||
private readonly ImmutableHashSet<Member> _unreachable;
|
||||
|
|
Загрузка…
Ссылка в новой задаче