-
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
Akka.Persistence: need to remove hard-coded Newtonsoft.Json object
serializer
#6389
Comments
Now I got it!!! This is the reason that the input of event adapter is always of Json.Net type... |
@Aaronontheweb which persistence plugin did you test this on? You should not override |
Ugh, lol. Needed it on SQL Server. |
Hi @Aaronontheweb , I found if I try to persist Tagged object, it always return to use Newtonsoft.Json object serializer (id=1) even I configured (Without tagging, it works very well...) Is it normal? |
Version Information
Version of Akka.NET? v1.4.49
Which Akka.NET Modules? Akka.Persistence and all derivatives
Related: #3811
Describe the bug
Per akkadotnet/Akka.Hosting#141
Persistence has its own default
System.Object
serializer settings here:https://github.com/akkadotnet/akka.net/blob/dev/src/core/Akka.Persistence/persistence.conf#L178
As far as I can tell, this cannot be overwritten.
I've attempted to override these in both of the following ways:
I still get
Newtonsoft.Json
as my serializer, even though I have explicitly overridden all of the appropriate settings. Akka.Remote uses the correct serializer. Persistence does not.I also tried overriding it programmatically:
Also did not work.
Expected behavior
Akka.Persistence should take its directions on serialization from Akka.NET, or at least be overridable using the appropriate settings.
Actual behavior
"Phasers had no effect, captain"
Additional context
I've discussed this before with @Arkatufus and we thought it might be unsafe to make this change - after looking more closely at it I don't think that's the case:
1
will still be read usingNewtonsoft.Json
.System.Object
serializer actually specified by the end-user.In other words, this isn't a destructive change at all - old data read using old method, new data read using configured method.
The text was updated successfully, but these errors were encountered: