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

[PROPOSAL] Custom connection pooling option for connection_class=RequestsHttpConnection. #203

Closed
Neckbuster opened this issue Sep 23, 2022 · 2 comments

Comments

@Neckbuster
Copy link
Contributor

What/Why

  • Custom Connection pooling option for connection_class=RequestsHttpConnection.
  • This feature is required because clients who are using advanced auth plugins options like AWS_IAM are forced to used RequestHttpConnection and are stuck with default values i.e 10 pool max_size provided in request library.

What are you proposing?

A new connection_class that will be a child class of RequestsHttpConnection with custom connection_pool option like pool_max_size that will be provided from client. The session attribute in RequestHttpConnection will be mounted with requests adapters with these pooling options.

@Neckbuster Neckbuster changed the title [PROPOSAL] [PROPOSAL] Custom Connection pooling option for connection_class=RequestsHttpConnection. Sep 23, 2022
@Neckbuster Neckbuster changed the title [PROPOSAL] Custom Connection pooling option for connection_class=RequestsHttpConnection. [PROPOSAL] Custom connection pooling option for connection_class=RequestsHttpConnection. Sep 23, 2022
@harshavamsi
Copy link
Collaborator

harshavamsi commented Sep 27, 2022

@Neckbuster I think this is a good idea. I see that the default connection class has the maxsize attribute. Would be nice to replicate that in the RequestHttpConnection class. Out of curiosity could you lay out your implementation idea here? To me it looks like you would not only need to update the pooling options in the session but also make use of self.pool.urlopen to allow for the actual pooling to take place?

Also can you take a stab at it with a PR?

@harshavamsi
Copy link
Collaborator

Closing via #216

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

No branches or pull requests

2 participants