aristidb / aws

Amazon Web Services for Haskell
BSD 3-Clause "New" or "Revised" License
238 stars 107 forks source link

Use http-client-tls global manager for http request by default. #251

Closed creichert closed 5 years ago

creichert commented 5 years ago

Default to using http-client-tls's global http manager by default instead of instantiating a new manager.

Creating a new Manager is a relatively expensive operation, you are advised to share a single Manager between requests instead.

It's probably possible to avoid the http-client-tls import (even though it's already a transitive dep) but the change would need a few more lines. I'm not certain it's worth the effort given the current patch's simplicity.

creichert commented 5 years ago

I know this project has been using travis for a while. But I could possibly expand build coverage greatly using my drop in circle-ci config which I can customize to support whichever lts or ghc versions you want.

aristidb commented 5 years ago

Looks good to me, I'm not worried about the additional direct dependency given that it's an indirect dependency already.

The Travis has been sort of broken for quite some time, and I don't really have much time to fix. If the Circle CI config works better, I'd be happy to look at a separate PR switching.