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 to override "User-Agent" header for client-side with application.conf #1492

Closed
apehovski opened this issue Oct 24, 2017 · 1 comment
Closed
Labels
2 - pick next Used to mark issues which are next up in the queue to be worked on. The tag is non-binding
Milestone

Comments

@apehovski
Copy link

apehovski commented Oct 24, 2017

Custom value for key "akka.http.client.user-agent-header" currently does not override default value.
As I see, also "akka.http.parsing" values affected.

Minor pull-request:
#1493

@jrudolph
Copy link
Member

There's indeed a problem here but I'd say it's a bit different:

  • currently, for pool usages, akka.http.host-connection-pool.client settings override the general client settings but fall back when missing (which is how it should be)
  • however, reference.conf contains a copy of the client settings (which we introduced, I think, to make the reference.conf more readable). That means, however, that akka.http.client settings never apply to the pool because we provide this copy in the reference.conf.

In fact, iirc, this whole setup was only done, to be able to provide a self-contained version of host-connection-pool settings which needs to wrap a set of client settings. Having to create self-contained versions of these settings seems to be a rare case, though.

The solution seems to be, to remove all concrete settings from akka.http.host-connection-pool.client, so that in general you can set settings just in akka.http.client and only have to use akka.http.host-connection-pool.client in special cases.

akka.http.{client,server}.parsing already uses the same style.

@jrudolph jrudolph added the 2 - pick next Used to mark issues which are next up in the queue to be worked on. The tag is non-binding label Nov 9, 2017
@jrudolph jrudolph added this to the 10.0.11 milestone Nov 9, 2017
jrudolph added a commit to jrudolph/akka-http that referenced this issue Nov 28, 2017
…on-pool.client

This way the defaults from akka.http.client automatically apply.

Fixes akka#1492.
jrudolph added a commit that referenced this issue Nov 29, 2017
…settings

=htc #1492 remove duplicate settings from akka.http.host-connection-pool.client
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2 - pick next Used to mark issues which are next up in the queue to be worked on. The tag is non-binding
Projects
None yet
Development

No branches or pull requests

2 participants