Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implements a connection pool. #17

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

sturzael
Copy link

@sturzael sturzael commented Jun 7, 2019

You aren't supposed to open and close the connection each time you make a new request.

This way, new connections can use the existing pool rather than having to wait for the previous one to be closed.

Don't repeatedly use connect() & end() as this will eventually cause issues. Just open it once and reuse it.

@sturzael
Copy link
Author

bump

@nax3t
Copy link

nax3t commented Nov 10, 2020

@sturzael I'm getting an error for connection.destroy() with your implementation: TypeError: connection.destroy is not a function

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants