3 ms·
The benchmark suited used the STDLIB json parser which is slow as hell. How slow is it? In 2011 there was a proposal to deprecate it, which never happened [1].
by valarauca1 11y ago
The benchmark suited used the STDLIB json parser which is slow as hell. How slow is it? In 2011 there was a proposal to deprecate it, which never happened [1].
Why? STDLIB parser loads the file line-by-line, then copies line by line into a new buffer that joins the strings together. Then the parser is called. The Scala community normally circumvents by using non-standard community developed solutions.
Furthermore JIT vs Compiled language benchmarks are pretty unfair to JIT'd languages. Especially for the JVM which doesn't start to compile sections until >10,000 calls.
[1] https://groups.google.com/forum/m/#!msg/scala-user/P7-8PEUUj6A/NonA0_IIovsJ https://groups.google.com/forum/m/#!msg/scala-user/P7-8PEUUj...
- jinst8gmi 11y agoWell that makes the result pretty much irrelevant as nobody actually uses that lib for any serious JSON parsing.
- kal31dic 11y agoSo which is the go to library for serious parsing in Scala? And how would you change the benchmark to make it fair ?
- justthistime_ 11y agoI'd use Jackson.