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

How to enable high security mode in Newrelic java agent (4.5.0) with environment variable



###Java Agent Question Template

  • Please provide a permalink - this allows our experts to see into the exact time and place. Only Relics will be able to view your data.

  • Feel free to add screenshots of any errors, or what you think the issue could be:

  • Add your Java agent version here (click for release notes):

  • Rule out some possible causes with our New Relic Diagnostics tool.

Is this a configuration issue? yes

  • Are you not seeing data? What frameworks are you using? We are using NR (4.5.0)

  • Describe what you are seeing: I have enabled NR agent but I am not seeing any logs in NR dashboard and the logs says you need to enable the high_security flag as the account is high security account but I have already set the NEW_RELIC_HIGH_SECURITY env key as true and I can confirm that it is there. My question is can’t we set this key when running our applications?

  • How does what you are seeing differ from what you expect to see? If I set the env variable for high security it should be able to ovveride it with the values available in newrelic.yaml. This thing is working for newrelic app name and license key.


Thanks for posting!

To understand why you can’t set high-security mode at runtime, it’ll be helpful to understand why high_security mode exists. Some customers have very sensitive, private customer information that sending to another company would violate their company privacy and this is a permanent concern. Also, there isn’t a NEW_RELIC_HIGH_SECURITY env key for the Java Agent. You can see a list here of usable environment variables for Java here:

May we have some more information about what you’re expecting to see? You mentioned not seeing logs but logs are not set to appear in APM by default. Here’s a quick refresh of what we expect from enabling high-security mode:

Enabling high security means SSL is turned on, request and message queue parameters are not collected, and queries cannot be sent to New Relic in their raw form.


Hi, @prakhar: Agent configuration via environment variables requires Java agent version 4.10.0 or higher.