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

feat: Add option to set http attributes when creating an instance of Client #20

Merged
merged 3 commits into from
Dec 16, 2017

Conversation

jrectenwald
Copy link
Contributor

This PR is addressing issue #13

The Problem
The issue requests the ability to override the Net::HTTP defaults for open and read timeouts.

What I did
I added a parameter called http_options to the Sendgrid::Client class. This parameter should be a hash with key/value pairs corresponding with attributes for NET:HTTP as described here. I added this in the test file and added this to the example file as well.

@thinkingserious thinkingserious added the status: code review request requesting a community code review or review from Twilio label Oct 11, 2017
@jrectenwald jrectenwald mentioned this pull request Oct 11, 2017
@@ -31,9 +31,11 @@ def setup
')
@host = 'http://localhost:4010'
@version = 'v3'

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jrectenwald Would you be OK with adding a duplicate test to this one, that doesn't pass http_options, so we can prove in the tests that it works both ways?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mbernier How's that?

@thinkingserious thinkingserious merged commit 1d5668a into sendgrid:master Dec 16, 2017
@thinkingserious
Copy link
Contributor

Hello @jrectenwald,

Thanks again for the PR!

We appreciate your contribution and look forward to continued collaboration. Thanks!

Team SendGrid DX

@SendGridDX
Copy link

SendGridDX commented Dec 16, 2017

CLA assistant check
All committers have signed the CLA.

@jrectenwald jrectenwald deleted the http-options branch October 27, 2018 22:22
@gareth gareth mentioned this pull request Sep 19, 2019
@thinkingserious thinkingserious changed the title Add option to set http attributes when creating an instance of Client feat: Add option to set http attributes when creating an instance of Client Jan 9, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
difficulty: medium fix is medium in difficulty status: code review request requesting a community code review or review from Twilio
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants