Petrik de Heus

71 Followers
62 Following
216 Posts
#RailsWorld session at the Richmond Hill skatepark.
@ioquatix There is a big difference in latency:
TechEmpower Web Framework Performance Comparison

Performance comparison of a wide spectrum of web application frameworks and platforms using community-contributed test implementations.

www.techempower.com

@ioquatix I have no idea what is causing it but there is a big difference in DB reads and writes for Falcon on the TechEmpower micro benchmarks.

For reads it's at the top

https://www.techempower.com/benchmarks/#section=data-r22&hw=ph&test=query&l=zijxtr-cn3&a=2&w=zdk8a7-zih7un-zik0zj-2pz3&f=3y8-0-0-2zgg-0-6bk-sg0-0-0-0-0-0-0-0-0

TechEmpower Web Framework Performance Comparison

Performance comparison of a wide spectrum of web application frameworks and platforms using community-contributed test implementations.

www.techempower.com

I've added `explain` support to Rails for methods like `last`, `pluck` and `count`:

https://github.com/rails/rails/pull/50482

This helps optimizing these queries.

Add `explain` support for methods like `last`, `pluck` and `count` by p8 · Pull Request #50482 · rails/rails

Motivation / Background explain can be called on a relation to explain how the database would execute a query. Currently explain doesn't work for queries using last, pluck or count, as these return...

GitHub
However, Agoo could probably be improved for when it's making database calls, as Unicorn and Puma score better:
https://www.techempower.com/benchmarks/#section=data-r22&hw=ph&test=update&l=zijxtr-cn3&a=2&w=zdk8a7-zih7un-zik0zj-2pz3&f=3y8-0-0-2zgg-0-6bk-sg0-0-0-0-0-0-0-0-0
TechEmpower Web Framework Performance Comparison

Performance comparison of a wide spectrum of web application frameworks and platforms using community-contributed test implementations.

www.techempower.com
If you include Agoo as a Rack server, it beats all other Rack servers on "JSON without a DB call" and "Plain text":
https://www.techempower.com/benchmarks/#section=data-r22&hw=ph&test=json&l=zijxtr-cn3&a=2&w=zdk8a7-zih7un-zik0zj-2pz3&f=3y8-0-0-2zgg-0-6bk-sg0-0-0-0-0-0-0-0-0
TechEmpower Web Framework Performance Comparison

Performance comparison of a wide spectrum of web application frameworks and platforms using community-contributed test implementations.

www.techempower.com
For database updates Unicorn seems the fastest. Falcon is very slow here, not sure if that is a misconfiguration.
https://www.techempower.com/benchmarks/#section=data-r22&hw=ph&test=update&l=zijxtr-cn3&a=2&w=zdk8a7-zik0zj-zik0zj-2pz3&f=3y8-0-0-2zgg-0-6bk-sg0-0-0-0-0-0-0-0-0
TechEmpower Web Framework Performance Comparison

Performance comparison of a wide spectrum of web application frameworks and platforms using community-contributed test implementations.

www.techempower.com
For database reads Falcon seems the fastest. I'd expect JRuby to score better here; maybe it needs a better connection pool configuration?
https://www.techempower.com/benchmarks/#section=data-r22&hw=ph&test=query&l=zijxtr-cn3&a=2&w=zdk8a7-zik0zj-zik0zj-2pz3&f=3y8-0-0-2zgg-0-6bk-sg0-0-0-0-0-0-0-0-0
TechEmpower Web Framework Performance Comparison

Performance comparison of a wide spectrum of web application frameworks and platforms using community-contributed test implementations.

www.techempower.com
TechEmpower Web Framework Performance Comparison

Performance comparison of a wide spectrum of web application frameworks and platforms using community-contributed test implementations.

www.techempower.com