-
Notifications
You must be signed in to change notification settings - Fork 1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
treat some deserialization errors as transient in remoting #3782
Conversation
this is a very welcome change I've been wanting to add myself. Thanks for handling it! I'll review it as soon as I can. |
…0641 * to be able to introduce new messages and still support rolling upgrades, i.e. a cluster of mixed versions * note that it's only catching NotSerializableException, which we already use for unknown serializer ids and class manifests * note that it is not catching for system messages, since that could result in infinite resending Do not tear down connections on IllegalArgumentException from serializer, Migrated from #24910
a9b670d
to
a5ad71c
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM - great change that should make life a lot better for Akka.Remote users.
@@ -157,7 +158,7 @@ public override object FromBinary(byte[] bytes, string manifest) | |||
if (_fromBinaryMap.TryGetValue(manifest, out var factory)) | |||
return factory(bytes); | |||
|
|||
throw new ArgumentException($"Unimplemented deserialization of message with manifest [{manifest}] in [{this.GetType()}]"); | |||
throw new SerializationException($"Unimplemented deserialization of message with manifest [{manifest}] in [{this.GetType()}]"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
|
||
|
||
[Fact] | ||
public void The_transport_must_stay_alive_after_a_transient_exception_from_the_serializer() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
ackAndMessage.MessageOption.RecipientAddress, | ||
ackAndMessage.MessageOption.SerializedMessage, | ||
ackAndMessage.MessageOption.SenderOptional); | ||
try |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
/// if the manifest is unknown.This makes it possible to introduce new message | ||
/// types and send them to nodes that don't know about them. This is typically | ||
/// needed when performing rolling upgrades, i.e.running a cluster with mixed | ||
/// versions for while. <see cref="SerializationException"/> is treated as a transient |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Comment is helpful and descriptive
…0641 (akkadotnet#3782) * to be able to introduce new messages and still support rolling upgrades, i.e. a cluster of mixed versions * note that it's only catching NotSerializableException, which we already use for unknown serializer ids and class manifests * note that it is not catching for system messages, since that could result in infinite resending Do not tear down connections on IllegalArgumentException from serializer, Migrated from #24910
…0641 (akkadotnet#3782) * to be able to introduce new messages and still support rolling upgrades, i.e. a cluster of mixed versions * note that it's only catching NotSerializableException, which we already use for unknown serializer ids and class manifests * note that it is not catching for system messages, since that could result in infinite resending Do not tear down connections on IllegalArgumentException from serializer, Migrated from #24910
…0641 (akkadotnet#3782) * to be able to introduce new messages and still support rolling upgrades, i.e. a cluster of mixed versions * note that it's only catching NotSerializableException, which we already use for unknown serializer ids and class manifests * note that it is not catching for system messages, since that could result in infinite resending Do not tear down connections on IllegalArgumentException from serializer, Migrated from #24910
treat some deserialization errors as transient in remoting
Migrated from
akka/akka#20641
akka/akka#24910