Skip to content

Most of the best-performing frameworks don't survive temporary db connectivity loss #8790

@itrofimow

Description

@itrofimow

TLDR: in the current top20 only 7 implementations survive a temporary database connectivity loss, other either hang, crash, or get stuck with http500.


I decided to become a QA engineer for a day and give frameworks a touch of real-world scenarios, to see how they would react.
I did this

  1. Launch the framework
  2. Poke it a bit to warm it up
  3. Restart the database
  4. Poke the framework some more

for every framework in the top20 of the most recent continuous run.

The results i've got:

Framework Outcome
may-minihttp hangs
xitca-web ✔️ (#8781)
just hangs
vertx stuck with 500/5021
h20 ✔️
redkale ✔️
officefloor hangs
drogon ✔️
viz stuck with 500/5021
axum stuck with 500/5021
jobby hangs
actix stuck with 500/5021
mormot ✔️
ntex hangs
vertx-web stuck with 500/5021
wizzadro_http ✔️
salvo crashes
aspnetcore ✔️
lithium ✔️
inverno hangs

Some of the rules in the spec are a bit vague, intentionally i believe, and Rule 1. of General Test Requirements is definitely one of such rules, but I would be very surprised to learn that the behavior observed qualifies as a "production-grade" in anyone's book.

Having a reliable way to recover from potential errors is likely to be not free performance-wise.
Some of the frameworks above come with configurations that behave reasonably in the scenario given,
but their reliability cost is not just "not free", it's staggering:
Axum, for example, which hits a very impressive 550K RPS and is ranked 9 in the "Single Query" test,
has a configuration that survives a database restart.
That configurations drops its performance to 90K RPS (x6 degradation2) and rank 262, even below MongoDB-based implementation for the test.


Considering the above, from a perspective of a web-developer who tries to choose a right tool for the job I personally find the performance figures shown misleading.

Curious to hear the community thoughts on the matter.

Footnotes

  1. By 502 I mean "closes the client connection right away" 2 3 4 5

  2. I think it's not configured optimally, but still

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions