papertrail / papertrail-cli

Command-line client for Papertrail hosted syslog & app log management service
http://papertrailapp.com/
MIT License
426 stars 46 forks source link

Stop using okjson #82

Closed sethherr closed 7 years ago

sethherr commented 7 years ago

ruby 2.2

okjson:       16.73s user 0.42s system 84% cpu 20.363 total
              15.22s user 0.28s system 57% cpu 26.961 total
              15.33s user 0.33s system 69% cpu 22.433 total

standard lib: 0.41s user 0.08s system 12% cpu 3.851 total
              0.45s user 0.09s system 10% cpu 5.085 total
              0.47s user 0.11s system 15% cpu 3.750 total

ruby 1.9

okjson:       41.27s user 1.38s system 95% cpu 44.581 total
              42.45s user 1.37s system 94% cpu 46.576 total
              41.86s user 1.33s system 94% cpu 45.644 total

standard lib: 0.72s user 0.09s system 31% cpu 2.592 total
              0.72s user 0.09s system 29% cpu 2.756 total
              0.71s user 0.09s system 29% cpu 2.736 total
sethherr commented 7 years ago

Reasons to use standard lib json - Mike Perham... who also points out that rails did it.

lmarburger commented 7 years ago

For historical record, some of us weren't able to replicate the performance impact of okjson vs ruby's built-in json. Even without a performance impact, using the native json library is a good thing so @sethherr is merging and cutting a release. 💯