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

feat: Include APM Labels in forwarded application logs.

Open jaffinito opened this issue 1 year ago • 2 comments

Description

Adds labels to in-agent forwarded logs.

  • Disabled by default
  • Labels are prefixed with "tags."
  • Labels are added to common attributes, not individual logs.
  • Allows individual labels to be excluded
  • Includes unit and integration tests

Author Checklist

  • [ ] Unit tests, Integration tests, and Unbounded tests completed
  • [ ] Performance testing completed with satisfactory results (if required)

Reviewer Checklist

  • [ ] Perform code review
  • [ ] Pull request was adequately tested (new/existing tests, performance tests)

jaffinito avatar Oct 11 '24 01:10 jaffinito

Note: Holding off on merging this until we get some official feature/notice text since this is a cross-agent feature.

jaffinito avatar Oct 28 '24 15:10 jaffinito

Codecov Report

Attention: Patch coverage is 97.50000% with 1 line in your changes missing coverage. Please review.

Project coverage is 81.43%. Comparing base (0278836) to head (8b8cb52). Report is 77 commits behind head on main.

Files with missing lines Patch % Lines
...c/Agent/Core/Configuration/DefaultConfiguration.cs 93.33% 0 Missing and 1 partial :warning:
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2831      +/-   ##
==========================================
+ Coverage   81.41%   81.43%   +0.01%     
==========================================
  Files         465      465              
  Lines       29535    29573      +38     
  Branches     3267     3275       +8     
==========================================
+ Hits        24047    24082      +35     
- Misses       4692     4693       +1     
- Partials      796      798       +2     
Flag Coverage Δ
Agent 82.36% <97.50%> (+0.01%) :arrow_up:
Profiler 73.07% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
...elic/Agent/Core/AgentHealth/AgentHealthReporter.cs 87.22% <100.00%> (+0.02%) :arrow_up:
...Relic/Agent/Core/Aggregators/LogEventAggregator.cs 94.84% <100.00%> (+0.10%) :arrow_up:
.../Agent/Core/Configuration/ReportedConfiguration.cs 95.79% <100.00%> (+0.03%) :arrow_up:
...erters/LogEventWireModelCollectionJsonConverter.cs 89.58% <100.00%> (+0.94%) :arrow_up:
.../Agent/NewRelic/Agent/Core/Labels/LabelsService.cs 90.47% <100.00%> (+0.82%) :arrow_up:
...c/Agent/NewRelic/Agent/Core/Metrics/MetricNames.cs 92.21% <100.00%> (+0.05%) :arrow_up:
...ent/Core/WireModels/LogEventWireModelCollection.cs 100.00% <100.00%> (ø)
...c/Agent/Core/Configuration/DefaultConfiguration.cs 89.65% <93.33%> (+0.03%) :arrow_up:

... and 2 files with indirect coverage changes

codecov-commenter avatar Feb 17 '25 15:02 codecov-commenter