Your data. Anywhere you go.

New Relic for iOS or Android


Download on the App Store    Android App on Google play


New Relic Insights App for iOS


Download on the App Store


Learn more

Close icon

Feature Idea: Support reading from environmental variable to disable .NET Core agent

feature-idea

#1

There’s other agents that support some variety of launch parameters and/or environmental variable conformance as to whether the New Relic agent runs or not.

.NET core relies on reading a XML file.

It should read from this in a tiered structure (similar to how AWS would get credentials), with the environment variable overriding the configuration file.

For anyone reading and wanting a workaround - we ultimately decided on it was easier to completely bypass the agent installation on envs that we did not want the agent running.


New Relic Edit

  • I want this too
  • I have more info to share (reply below)
  • I have a solution for this

0 voters

We take feature ideas seriously and our product managers review every one when plotting their roadmaps. However, there is no guarantee this feature will be implemented. This post ensures the idea is put on the table and discussed though. So please vote and share your extra details with our team.


#2

Hey @charles.lee - Thanks for posting your feature idea here. I’ve got that filed internally now & I have added a poll here for others to vote on. :smiley:


#3

You’ve got to be kidding me right? Is this still not possible?
I need to disable the agent for Test, Acceptance and Staging, using Docker.
The image we build is exactly the same for Staging and Production, so how on earth can I disable the agent based on the environment it’s running on if this is not possible yet???


#4

Setting CORECLR_ENABLE_PROFILING=0 seems like a valid work-around.


#5

Yes, the above solution will work.

CORECLR_ENABLE_PROFILING=0

This is the Microsoft-defined method for disabling all .NET Core profiling via an environment variable.