Comments (6)
Hi @oliverjanik ,
Thanks very much for your suggestion. I think you have a good idea. It would be a good thing to allow support for alternative JSON implementations. Currently, the Java driver is exploring something like this too: rethinkdb/rethinkdb#5128
However, currently the driver relies on some Newtonsoft feature-magic (objects like JObject
, JArray
, and JToken
) to get its work done. It would take some effort to re-factor the source to allow multiple JSON implementations, but should be do-able.
EDIT: Requires #77 to be implemented first.
Updated Benchmarks (thanks to @marshall007):
http://theburningmonk.com/2016/01/binary-and-json-benchmarks-updated-4/
from rethinkdb.driver.
It's good to hear you're open to suggestions.
Newtonsoft is one of the slowest json serializers around and has some crazy baggage (e.g. JamesNK/Newtonsoft.Json#525)
from rethinkdb.driver.
Hey Oliver, yeah. I totally understand. I've heard some arguments on both sides regarding Newtonsoft. Microsoft blessed Newtonsoft as the default JSON ser/des in ASP.NET MVC and it was one reason I picked it as the default here.
Currently, I don't have any immediate needs for an alternative JSON implementation right now, so this is a bit lower priority issue for me. However, I'd gladly help with guidance and accept a PR if you or anyone want to take a stab at it.
Side note: It would be interesting to see an updated version of the benchmarks. Looks like the benchmarks were ran against v6.0.7
some time ago. I think we're at v8+
now. I wonder if Newtonsoft made any progress at closing the gap since v6.0.7
.
from rethinkdb.driver.
I think they are always working on improving performance of it http://james.newtonking.com/archive/2015/12/20/json-net-8-0-release-1-allocations-and-bug-fixes
from rethinkdb.driver.
And it's not too bad if you look at some benchmarks (which already look out of date)
http://theburningmonk.com/benchmarks/
from rethinkdb.driver.
It's less the speed, more the wild and inconsistent API and true WTF moments (like the one I linked to) for me.
Call me sceptical but a library that modifies! my timestamp by just loading json as JObject is an absolute no-go. Moreover there was zero discussion and the issue closed as won'tfix.
from rethinkdb.driver.
Related Issues (20)
- Create a method to return result as raw json HOT 4
- Resolution function on OptArg insert conflict HOT 1
- ConnectionPool.Builder.ConnectAsync does not respect InitialTimeout() HOT 4
- Add Error codes to Exceptions HOT 2
- Additional exceptions thrown when trying to cancel Cursor.MoveNextAsync() HOT 6
- Object's primary key and key of RunAtom() is different (Client-side generation). HOT 4
- Support for System.Text.Json.JsonDocument
- Cursor<T> should implement IAsyncEnumerable<T> in .net core 3
- RethinkDB 2.4 Release
- Best options: RunResult, RunAtom or RunCursor HOT 3
- Get list from Table that contains 'A' in the 'message' field HOT 1
- ASL 2.0 HOT 1
- Implement lambda functions as a possible argument in Insert().OptArgs("conflict",...) HOT 1
- System.NullReferenceException HOT 1
- Add EntityFramework support to Linq provider HOT 5
- Polymorphism HOT 1
- Various exceptions when updating a document HOT 1
- System.Configuration.ConfigurationErrorsException: HOT 1
- Wrong OptArg serialisation after OrderBy
- Insert not working with RunNoReply & Can't use runOpts is always null -- solved
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from rethinkdb.driver.