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

Allow for hackney options #468

Merged
merged 1 commit into from
Feb 9, 2023
Merged

Allow for hackney options #468

merged 1 commit into from
Feb 9, 2023

Conversation

danschultzer
Copy link
Contributor

This PR makes it possible to set :hackney_opts in the configuration which is passed onto hackney. I didn't see any tests of configuration, but this works in local for me. This resolves the first part of #467.

To force IPv6 with hackney I can now set the config with:

config :honeybadger,
  # ...
  hackney_opts: [connect_options: [:inet6]]

But dual stack could still be an issue since it'll always default to IPv4 in hackney.

As discussed in #467 it would be better if it was possible to pass in a HTTP client adapter. That would remove things that arguably should be outside the scope of this library, like the HTTP proxy tunnel or the connection pool. The default startup could still include hackney with some sane defaults (e.g. starting connection pool).

Copy link
Collaborator

@sorentwo sorentwo left a comment

Choose a reason for hiding this comment

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

These changes look great as a stop-gap until we have pluggable clients. I'm going to merge this in for now, but the changes may be overwritten with client changes before the next release.

@sorentwo sorentwo merged commit 714b60e into honeybadger-io:master Feb 9, 2023
@danschultzer danschultzer deleted the hackney-opts branch February 13, 2023 21:42
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