MemberRemovedevent is not received or processed correctly
Hi everyone! I'm struggling with extending class for already persisted messages. I added new field, new messages are serializing propeply but when I try to recover my actor I receive
Persistence failure when replaying events for persistenceId [someId]. Last known sequence number ", "timestamp": "2017-01-31 09:30:05.9723", "stack": "System.InvalidCastException: Okre\u015blone rzutowanie jest nieprawid\u0142owe.\r\n w lambda_method(Closure , Stream , DeserializerSession )\r\n w Hyperion.ValueSerializers.ObjectSerializer.ReadValue(Stream stream, DeserializerSession session)\r\n w Hyperion.Serializer.Deserialize[T](Stream stream)\r\n w Akka.Serialization.HyperionSerializer.FromBinary(Byte bytes, Type type)\r\n w Akka.Persistence.Sql.Common.Journal.AbstractQueryExecutor.ReadEvent(DbDataReader reader)\r\n w Akka.Persistence.Sql.Common.Journal.AbstractQueryExecutor.<SelectByPersistenceIdAsync>d__44.MoveNext()\r\n--- Koniec \u015bladu stosu z poprzedniej lokalizacji, w kt\u00f3rej wyst\u0105pi\u0142 wyj\u0105tek ---\r\n w System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n w System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n w Akka.Persistence.Sql.Common.Journal.SqlJournal.<ReplayMessagesAsync>d__32.MoveNext()" }
According to Hyperion's documentation, it's version tolerant, so as far as I understand this therm, it means I should be able to add/remove field to the contract. I created simple project https://github.com/mwpro/Hyperion-VerionTolerance that reproduces my issues. Can you guys look at it please and tell me if I am doing something wrong or if there is some king of bug with version tolerance?
@Horusiath In my example, when I once serialize my object with two properties (string and int, Step 1), and then I add a new property to the class I cannot have my object deserialized (steps 3, 4, 5). Adding a new field only worked for a string property at the end of class (step 2).
But if the order and type of fields matters as you said, then it makes some sense why they are not deserialized properly.