How to exiting gracefully?
See original GitHub issueBefore exiting, I want to wait all queries finished, then connection destroyed gracefully. Like calling ‘end’ method in mysql
package.
Is there any way to do this in sequelize? I found destroy
$disconnect
method in connectionManager, but I didn’t find the way to call them from a Sequelize
instance.
Issue Analytics
- State:
- Created 8 years ago
- Reactions:1
- Comments:7 (3 by maintainers)
Top Results From Across the Web
Exiting Gracefully - Rich Mironov
Talk your CEO through your exit story and agree on it. Send/email your proposed language. Offer to continue saying nice things about the...
Read more >How to Exit an Organization Gracefully and Why It Matters
1. Ask for what you need · 2. Maintain clear lines of communication · 3. Set reasonable boundaries · 4. Practice acceptance ·...
Read more >How to Leave Your Job Gracefully - Harvard Business Review
Work hard until your last day. Don't sully your hard-won reputation by slacking off at the end. Go out on a high note...
Read more >Graceful exit - Wikipedia
A graceful exit (or graceful handling) is a simple programming idiom wherein a program detects a serious error condition and "exits gracefully" in...
Read more >How to end and exit a conversation gracefully - TES
Another way to exit a conversation is to express appreciation for something that the other person said or did. I appreciate you helping...
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
So the succint answer is
sequelize.connectionManager.close().then(() => console.log('shut down gracefully'));
for anyone else coming here.I guess as of now you can use
sequelize.close().then..