Open
Description
The logger does not use process_host.display_name
when setting hostname
in the logs. Instead it uses Socket.gethostname
via a call to NewRelic::Agent::Hostname.get
.
I believe it is a bug. (In another issue, a New Relic developer assumes the feature already acts this way when she says "Alternatively, we have the ability to set the app name (entity.name in the default attributes) and hostname by configuration in either the newrelic.yml file or by environment variable"). #1141
You can see the offending code here:
I think the fix is to just replace with:
Agent.config[:'process_host.display_name']
I can create a PR if that would be helpful.
Thanks!