I've been using JSON.Net to serialize objects to and from JSON for years.
However, ever since I heard that ServiceStack had a faster JSON serializer I've wanted to try it.
After all, speed is important, especially on a mobile devices, and if I can make my code run faster by just swapping out one third party library for another then that's a simple decision.
Today I finally got around to trying it and to do so I built a console app so I could put the two methods side by side.
Look both methods are very similar. And as I rarely do anything more complicated with JSON than just serialize or deserialize this is great.
Obviously the above isn't enough for me to prove that it's faster. I'm just trusting the benchmark testing done by others.
It's also a smaller DLL so it will reduce the overall XAP size and download time. Plus app load time too. :)
My only slight reservation is that ServiceStack doesn't give me the debugging assistance I get with Json.Net. Maybe I'll look to just use Json.Net in the debug build if this becomes an issue.
You know your projects stand out of the herd. There is something special about them. It seems to me all of them are really brilliant!
ReplyDeleteThanks for the such a wonderful post and great coding. I love it very much
ReplyDeletehey
ReplyDelete