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

Chunk endcoding is broken when Microsoft.AspNetCore.Diagnostics.Abstractions is missing


We have noticed that RavenDB server doesn’t work in conjunction with new relic .net agent.

I’ve create simple application which demonstrates an issue:

Please configure your New Relic agent using 4 ENV properties:

Please try to run this application. It should work fine.

Then remove dependency from csproj file:
<PackageReference Include=“Microsoft.AspNetCore.Diagnostics.Abstractions” Version=“2.1.1”/>

and run server, it doesn’t work.

Chrome compains with: databases:1 GET net::ERR_INCOMPLETE_CHUNKED_ENCODING 200 (OK)

When I use telnet we can see that final chunk is missing. (0\r\n\r\n).

Source issue:


Hi @marcin4,

RavenDB is not one of the datastores that is supported by the .NET agent:

What this means is we are unable to dedicate developer resources to resolving any conflicts the agent might have when using this database. I’ve opened a ticket so I could file a feature request on your behalf to provide support for this database. I would also strongly encourage you to head over to our Feature Ideas section and post a request to support this database:

Doing this will allow others in the community to vote on the request. Our product managers review all of these requests. While we can’t guarantee when or if this feature will be implemented, we take customer requests very seriously and use them to prioritize which features we implement next.

In the meantime, another community member may have encountered this previously and have a workaround. I’ll keep a watch on this to see if a solution is offered.


I wouldn’t bother about RavenDB support for now. The bad thing is that your product requires library (Microsoft.AspNetCore.Diagnostics.Abstractions) to work or it breaks completely. So you make assumption in code on something that might not be always available. Please have a look at sample github project. It doesn’t use RavenDB at all. It uses kestrel.

For me the current fix would be:
If Microsoft.AspNetCore.Diagnostics.Abstractions is not available on path, then don’t try to instrument this application as it will break anyway. It is better solution than, saying: I can’t install new relic globally as it will break my kestel based apps.


Hi @marcin4,

I see what you’re saying. Yes, this seems like it might be a more serious issue based on the dependency. However, I just noticed the version was set to 2.1.1. I would suggest reviewing the release notes for v8.4.880.0 of the agent:

There was a bug in the .NET Core libraries that prevented our agent from working correctly with earlier versions of 2.1. We require the use of the .NET CoreCLR v2.1.3 or newer. It’s possible the issue you’re seeing may be resolved by updating the version of .NET Core installed on the system. If it is not, we first need to make sure you’re running the latest version of the agent (v8.9.130.0 right now), then see if it is still reproducible. Should that be the case, we can file this with our developers.


will recheck that in spare moment.


Hey @marcin4 - did you get some time to check up on the version of the agent, and the version of .Net Core installed as @kyle recommended??


I can confirm it works using NewRelic.Agent.Core.dll in version: and it doesn’t work using:


Hey @marcin4 - Sounds like you got this working now with, is that right?