urbanairship / ruby-library

A Ruby wrapper for the Urban Airship API.
Other
200 stars 117 forks source link

Add request timeout option on configs #110

Closed ricardoruwer closed 6 years ago

ricardoruwer commented 6 years ago

What does this do and why?

As read on the UrbanAirship docs: "Setting a timeout limit of 60 seconds can result in higher success rates when accessing our API during extremely high loads." but how to do that?! So, this PR adds the option to change the request timeout using the UrbanAirship configurations.

For example:

Urbanairship.configure do |config|
  config.timeout = 60
end

Testing

andremnds commented 6 years ago

Nice! 🔥 🔥

aschuman0 commented 6 years ago

@ricardoruwer - Thank you for the contribution and for signing the contribution form. Apologies that this has taken us some time to get to. We are taking a look now and will hopefully include this in the next release. -Aaron, Urban Airship Customer Engineering

aschuman0 commented 6 years ago

This looks good. Going to merge this in so you can build from this source if need be. Otherwise, we should be pushing out a release with this change in the next few days. Thanks again!

aschuman0 commented 6 years ago

This has been released to rubygems with version 4.1.1 today. Thank you again for the contribution!