-
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
Implement cross-platform json serializer and spec #2947
base: dev
Are you sure you want to change the base?
Implement cross-platform json serializer and spec #2947
Conversation
{ | ||
string data = JsonConvert.SerializeObject(obj, Formatting.None, Settings); | ||
#if CORECLR | ||
data = data.Replace("System.Private.CoreLib", "%CORE%"); |
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.
it is not enough. There is more System.Private.*
assemblies, like System.Private.Uri
Hi, we are potentially looking at doing this as we have certain back end services which will take 6 to 12 months to convert to .Net Core. One question: when you say lower performance on the serializer, do you have any feel for how much of a performance hit we would be talking? Are we talking 10-20% hit or 80-90% hit? |
We are also interested in a hybrid architecture consisting of some legacy systems on full framework, and new development with .NET Core. |
I copy this serializer and it work for me. (Client .net 4.7.1 -> Cluster .net Core 2.0) I have to Add a specific Identifier and replace the Preprocess condition "#if CORECLR" by a runtime check if i'm runing in .net core or .net classic. For now the only solution i found to check if i run in .net core is :
|
@notour would you like to send an updated PR with that code change? Appreciate the info! |
We're looking for this capability also. |
…the specifc preprocess check
I made a pull request : |
Allow the compat serializer to run on different evenvironment
I have an implementation for Hyperion to work across .Net Core to .NET Full framework. Currently it supports collections that switch between mscorlib to System.Private.CorLib as well as ExpandoObjects going from System.Dynamic to System.Linq. |
Hello, What is the current state of this? We are (unfortunately) still having to target .NET Framework as the WPF on .NET Core will not be ready for us in time and have just hit this issue. Regards |
@john-cullen we should probably implement @leo12chandu's changes |
@Aaronontheweb - I would be happy to branch out from akka.net master, implement it and create a pull request for you to review if it helps merge so others can use it. I've performance tested it 6 months back with reasonable size payloads and its does not add more than 10-20 milliseconds for our objects with over a 1000 properties per object. Usage defined at #3587 |
Any developments? We have a situation of a legacy .net framework app, new actors in .net core core... and I was pleasantly surprised today to find there is some level of interoperability out of the box (it formed a cluster, an actor in .net core taking strings from actor in .net framework worked fine) |
@awostenberg I went with modifying the serialised text for now. I've not had any problems with it (but my app is still in testing / pre-release) https://gist.github.com/john-cullen/c39d56efcb15e60b66cd4d05149316ed |
@john-cullen you saved me. It took me 3 days of banging my head against why our system is just not working. Long and behold once we connected our WPF .NET framework clients they don't communicate messages with arrays in them (with cryptic dissociation errors). Once I discovered this thread I was concerned that this is going to be a showstopper for our effort to port our WCF to akka.net (months of effort), since our WPF apps can't be converted to .net core anytime soon. It would be really nice, going forward, to integrate @leo12chandu solution for planed 1.5 release when akka.net switches to Hyperion. Thanks. |
@Arkatufus I know you're OOF, but maybe we should just merge this in - I can think of several support customers who are going to run into this as they execute their migrations off of .NET Framework this year. |
Probably need a feature toggle for this. |
NOTE: