-
Notifications
You must be signed in to change notification settings - Fork 62
Description
Hyperion does not seem to deserialize ObjectDisposedException
. Got many problems because it was wrapped in some messages containing the Exception but could reproduce it in the end with this simple lines:
var message = new ObjectDisposedException("oh no");
var serializer = system.Serialization.FindSerializerFor(message);
var binary = serializer.ToBinary(message);
var msg = serializer.FromBinary(binary, null);
Error is:
An exception occurred, System.MissingMethodException: No parameterless constructor defined for this object.
The error feels misleading as most immutable Akka messages do not have a parameterless constructor. Also it does not mention the class where it misses the constructor. I wrapped the Akka.Serialization.HyperionSerializer
with my own Akka serializer but I could also track the outer-most parent class. That was in my case Akka.Actor.Status.Failure
so it took my a while to go down to ObjectDisposedException
.
Versions:
- Akka 1.2.3
- Akka Remote 1.2.3
- Akka.Serialization.Hyperion 1.2.3.43-beta
- Hyperion 0.9.2
A temporary workaround to replace those instances with null
would be appreciated.