Connection error : EAGAIN
See original GitHub issueIssue Description
Sequelize issues EAGAIN error randomly
What are you doing?
Stressful event of multiple file uploadings in parallel at high bandwidth
What do you expect to happen?
Not to crash
What is actually happening?
Additionnal information
Can’t be replicated easily, so no minimal example, sorry. It only seems to happen when connections are throttled by the server.
Environment
- Sequelize version: sequelize@5.19.4
- Node.js version: v8.16.1
- Operating System: SMP Debian 4.9.130-2 (2018-10-27) x86_64 GNU/Linux in Vagrant box
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 ‘mysql’, with connector library version XXX and database version
mysql Ver 15.1 Distrib 10.1.41-MariaDB, for debian-linux-gnu (x86_64) using readline 5.2
(how am I supposed to find the connector version ?)
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:
- Created 4 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
Linux socket send() error EAGAIN - Stack Overflow
I am using non-blocking sockets, and the socket is closed then re-opened between connect attempts.
Read more >WHY DOES SEND() RETURN EAGAIN / EWOULDBLOCK?
If your socket is in 'non blocking' mode then the 'send()' will fail with 'EAGAIN' or 'EWOULDBLOCK' (often the same error number)
Read more >Why does recvfrom() call return EAGAIN error?
When recvfrom is used on a non-blocking socket, it returns EAGAIN error if there are no pending data to be read.
Read more >bt_conn_le_create will return an error -11 (EAGAIN)
I am trying to create several client connections for different servers. The code is incomplete at the moment as the focus is on...
Read more >Added information about what can cause EAGAIN and ... - kernel
I have found that these errors can also occur when a receive timeout has been set on the socket and the timeout expires...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Reduced the pool minimum number of connections to zero. Trying to reliably fix and test that for a production environment would be a nightmare and I don’t mind a tiny bit of latency when reconnecting since database is local
This was indeed a problem with Sequelize. The connection pool I used had a minimum of five connections, and those connections would get into an invalid state after being inactive after some time. Trying to use them before they get evicted from the pool, but after getting into this invalid state, triggers the error. I hope this can help someone in the future