[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[requirements][placement] orjson instead of stdlib json

On Wed, 28 Aug 2019, Matthew Thode wrote:

> Looking through global-reqs, some more it looks like simplejson can be c
> based and is in global-reqs as well.
> Looking at the benchmarks orjson itself provides it's hard to see how it
> can be 100x faster than even the native json.

I've tried the other options and they don't provide as much
improvement as orjson, nor are they as healthy with regard to
project activity and JSON correctness.

I suspect the reason my tests are seeing such a huge improvement
(different from orjson's benchmark) is because this is one single
very large (2583330 bytes when JSON) python structure being
dumped just once.

The benchmarks on the pypi page that fit most are those with
canada.json (which happens to the be one where orjson seems to have
the biggest advantage).

It's not the end of the world if we don't switch, but thought I
would raise the topic to see if it was worth pursuing.

Chris Dent                       Ù©â??̯â??Û¶           https://anticdent.org/
freenode: cdent