Profiler chaining for the .NET Core agent
You can use profiler chaining to run the .NET Core agent alongside another .NET Core APM profiler.
The Contrast .NET Core agent is tested and proven to be compatible with the following profiling tools, given the combination of runtime, deployment type, and OS:
Profiling tool | Versions tested | .NET Core runtime | Third-party profiler deployment type | OS |
---|---|---|---|---|
Dynatrace One Agent | 1.193.159.20200602-190835 | 3.1 | Installed | Windows Server 2019 |
New Relic (see example) | 8.23.107 | 3.1 | NuGet Package | Windows Server 2019 |
Note
The agent is likely compatible with other profiling tools if those tools follow the conventions of the CoreCLR Profiling API and do not make assumptions about the profiling environment.
IIS
Install the third-party agent, then the Contrast .NET Core agent.
Note
You must use the installed agent, not the manual agent.
Dynatrace chaining is only supported for installed IIS agent.
Enable profiler chaining, configure the .NET Core agent so that the
agent.dotnet.enable_chaining
setting is set totrue
. For example, you could use this YAML configuration:agent: dotnet: enable_chaining: true
Once configured, you must restart the agent. On restart, the Contrast .NET Core agent automatically detects the presence of other profiling tools registered with IIS and configures the environment to load both the Contrast .NET Core agent profiler and the third-party profiler.
Outside of IIS
The agent.dotnet.enable_chaining
configuration flag will not work if you are using profiler chaining for applications:
hosted outside of IIS, or
that use the third-party agent's Nuget package (rather than the installed agent).
Replace the CLR environment variables for the profiling tool with CONTRAST_CCC_COR versions. Any of these names should be transformed:
Change this
To this
COR_PROFILER
CONTRAST_CCC_COR_PROFILER
COR_PROFILER_PATH
CONTRAST_CCC_COR_PROFILER_PATH
COR_PROFILER_PATH_32
CONTRAST_CCC_COR_PROFILER_PATH_32
COR_PROFILER_PATH_64
CONTRAST_CCC_COR_PROFILER_PATH_64
Make the necessary changes in your APM profiler. Here are examples for New Relic.