newrelic-dotnet-agent icon indicating copy to clipboard operation
newrelic-dotnet-agent copied to clipboard

Support NEW_RELIC_ERROR_COLLECTOR_EXPECTED_ERROR_CODES and NEW_RELIC_ERROR_COLLECTOR_IGNORE_ERROR_CODES environment variables

Open dggmez opened this issue 1 year ago • 2 comments

Is your feature request related to a problem? Please describe.

We can only use either .NET configuration providers and environment variables to configure the New Relic agent. Right now, the error collector can only be configured through a newrelic.config file.

Feature Description

I would like to see support the NEW_RELIC_ERROR_COLLECTOR_EXPECTED_ERROR_CODES and NEW_RELIC_ERROR_COLLECTOR_IGNORE_ERROR_CODES environment variables. Those environment variables are already supported by the Node.js agent:

https://docs.newrelic.com/docs/apm/agents/nodejs-agent/installation-configuration/nodejs-agent-configuration/

Describe Alternatives

I mean, if the error collector could be configure through any .NET configuration provider it would also work. We could set the configuration through either environment variables, KeyVault, file configuration (appsettings.json), etc. and to be honest that's the way we configure everything through .NET configuration providers except New Relic :(. Sadly that alternative is NOT supported either:

https://forum.newrelic.com/s/hubtopic/aAX8W0000008ci1WAA/net-configure-net-agent-error-collector-with-appsettingsjson

Additional context

I hope everything is clear and no additional context is needed.

Priority

Please help us better understand this feature request by choosing a priority from the following options: [Really Want]

dggmez avatar Jan 10 '24 01:01 dggmez

https://new-relic.atlassian.net/browse/NR-213878

@dggmez Thanks for creating this feature request. We have a few other existing requests to support environment variables for configuration, and we're looking at adding support for all configuration options via environment variables, though there's currently no timetable for that effort. We'll keep your request in our backlog and update it when we make progress.

tippmar-nr avatar Jan 10 '24 20:01 tippmar-nr