question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Severe performance issues

See original GitHub issue

Issue Description

What are you doing?

Running a web server that does 1 SQL query and returns results:

const tag = await models.tag.findOne({
	where: {name: ctx.params.name},
});

What do you expect to happen?

3500+ req/s

What is actually happening?

460 req/s

Additional context

  1. I tried patching the native Promise to add some extra functions that behave like Bluebird, and I was able to go up to ~830 req/s by ditching out Bluebird entirely.
  2. I did a benchmark to my webserver with solely Redis query, it can do up to ~3500 req/s on a single CPU core.
  3. I benchmarked mysql2, it can do up to 108,000 req/s - which is pretty much however fast is my running MariaDB server.

With that in mind, I believe sequelize does introduce extremely awkward procedures that bring the speed down to 430 req/s - note that it should ideally do 50,000+ queries/s assuming the webserver in front of it is ditched away.

Environment

  • Sequelize version: 4.44.3
  • Node.js version: 12.11.1
  • Operating System: Arch Linux

Issue Template Checklist

How does this problem relate to dialects?

  • I think this problem happens regardless of the dialect.
  • I think this problem happens only for the following dialect(s):
  • I don’t know, I was using PUT-YOUR-DIALECT-HERE, with connector library version XXX and database version XXX

Would you be willing to resolve this issue by submitting a Pull Request?

  • Yes, I have the time and I know how to start.
  • Yes, I have the time but I don’t know how to start, I would need guidance.
  • No, I don’t have the time, although I believe I could do it if I had the time…
  • No, I don’t have the time and I wouldn’t even know how to start.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:16 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
SimonSchickcommented, Apr 25, 2020
0reactions
sushantdhimancommented, Apr 25, 2020

@jedwards1211 is working on tests (converting them to async) @kroleg you can help us with documentation cleanup 😃

Read more comments on GitHub >

github_iconTop Results From Across the Web

Suffering Severe Performance Issues - Microsoft Community
I've noticed a drastic drop in my laptop performance levels of lately since I've been paying more attention to aspects like memory use...
Read more >
Dealing with Performance Problems
Types of Performance Problems ; Quantity of work (untimely completion, limited production). Poor prioritizing, timing, scheduling; Lost time ; Quality of work ( ......
Read more >
Permanently Resolve Your Organization's Chronic Performance
Check out the new article Permanently Resolve Your Organization's Chronic Performance Issues on thedorseygroup.org.
Read more >
Troubleshooting Game Performance Issues - Hardware
Game performance problems, such as slow frame rates or occasional slow frames, can be caused by bugs or inefficient coding in the games,...
Read more >
Severe Performance Issues : r/buildapc - Reddit
My game would completely freeze for seconds ever ten or so seconds. I checked Task Manager and my CPU, Memory, and GPU were...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found