Skip to content

Conversation

@hmstepanek
Copy link
Contributor

@hmstepanek hmstepanek commented Oct 2, 2025

Overview

This adds support for the concept of partial granularity distributed traces. There are 3 types:

  • reduced
  • essential
  • compact

Add support for the following new configuration options:

distributed_tracing
   sampler
       adaptive_sampling_target
       full_granularity
           enabled
           remote_parent_sampled
           remote_parent_not_sampled
       partial_granularity
           enabled
           type
           remote_parent_sampled
           remote_parent_not_sampled

@hmstepanek hmstepanek requested a review from a team as a code owner October 2, 2025 17:59
@github-actions
Copy link

github-actions bot commented Oct 2, 2025

MegaLinter analysis: Success

Descriptor Linter Files Fixed Errors Warnings Elapsed time
✅ ACTION actionlint 7 0 0 0.92s
✅ MARKDOWN markdownlint 7 0 0 0 1.41s
✅ PYTHON ruff 948 0 0 0 0.96s
✅ PYTHON ruff-format 948 0 0 0 0.42s
✅ YAML prettier 15 0 0 0 1.54s
✅ YAML v8r 15 0 0 6.83s
✅ YAML yamllint 15 0 0 0.71s

See detailed reports in MegaLinter artifacts

MegaLinter is graciously provided by OX Security

@mergify mergify bot added the tests-failing Tests failing in CI. label Oct 2, 2025
@codecov-commenter
Copy link

codecov-commenter commented Oct 2, 2025

Codecov Report

❌ Patch coverage is 89.95434% with 22 lines in your changes missing coverage. Please review.
✅ Project coverage is 81.76%. Comparing base (59633ac) to head (c08ab1a).
⚠️ Report is 3 commits behind head on develop-hybrid-core-tracing.

Files with missing lines Patch % Lines
newrelic/config.py 51.72% 14 Missing ⚠️
newrelic/core/node_mixin.py 94.54% 1 Missing and 2 partials ⚠️
newrelic/core/agent.py 50.00% 2 Missing ⚠️
newrelic/core/data_collector.py 71.42% 1 Missing and 1 partial ⚠️
newrelic/api/transaction.py 98.27% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@                      Coverage Diff                      @@
##           develop-hybrid-core-tracing    #1532    +/-   ##
=============================================================
  Coverage                        81.76%   81.76%            
=============================================================
  Files                              207      207            
  Lines                            23943    24072   +129     
  Branches                          3796     3819    +23     
=============================================================
+ Hits                             19576    19682   +106     
- Misses                            3101     3119    +18     
- Partials                          1266     1271     +5     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@hmstepanek hmstepanek force-pushed the partial-granularity-type-support branch from 831fa32 to ca79220 Compare October 7, 2025 00:07
@hmstepanek hmstepanek marked this pull request as draft October 7, 2025 00:08
@hmstepanek hmstepanek force-pushed the partial-granularity-type-support branch 6 times, most recently from 303468c to 27573b4 Compare October 10, 2025 22:26
@hmstepanek hmstepanek force-pushed the partial-granularity-type-support branch from 7282263 to b59cc63 Compare October 21, 2025 17:21
@hmstepanek hmstepanek changed the base branch from main to develop-hybrid-core-tracing October 21, 2025 17:36
@hmstepanek hmstepanek force-pushed the partial-granularity-type-support branch 3 times, most recently from 4c9dd32 to b962aba Compare October 22, 2025 07:13
@hmstepanek hmstepanek marked this pull request as ready for review October 22, 2025 07:19
@hmstepanek hmstepanek force-pushed the partial-granularity-type-support branch 2 times, most recently from 0262e1a to 81943d0 Compare October 22, 2025 08:25
@hmstepanek hmstepanek force-pushed the develop-hybrid-core-tracing branch from e3f2de1 to 01b71d0 Compare October 22, 2025 17:32
@mergify mergify bot added the merge-conflicts Merge conflicts detected. label Oct 22, 2025
@hmstepanek hmstepanek force-pushed the partial-granularity-type-support branch from ddd7851 to d3152cb Compare October 22, 2025 17:35
@mergify mergify bot removed the merge-conflicts Merge conflicts detected. label Oct 22, 2025
@hmstepanek hmstepanek force-pushed the partial-granularity-type-support branch from d3152cb to eaa838d Compare October 22, 2025 21:02
@hmstepanek hmstepanek force-pushed the develop-hybrid-core-tracing branch from 01b71d0 to 48c4420 Compare October 22, 2025 22:40
@mergify mergify bot added the merge-conflicts Merge conflicts detected. label Oct 22, 2025
hmstepanek and others added 6 commits October 27, 2025 16:48
* fix(aiomysql): avoid wrapping pooled connections multiple times

* Move and rewrite regression test

* Tweak implementation of fix

---------

Co-authored-by: Tim Pansino <[email protected]>
Bumps the github_actions group with 4 updates: [actions/upload-artifact](https://github.com/actions/upload-artifact), [actions/download-artifact](https://github.com/actions/download-artifact), [astral-sh/setup-uv](https://github.com/astral-sh/setup-uv) and [github/codeql-action](https://github.com/github/codeql-action).


Updates `actions/upload-artifact` from 4.6.2 to 5.0.0
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](actions/upload-artifact@ea165f8...330a01c)

Updates `actions/download-artifact` from 5.0.0 to 6.0.0
- [Release notes](https://github.com/actions/download-artifact/releases)
- [Commits](actions/download-artifact@634f93c...018cc2c)

Updates `astral-sh/setup-uv` from 7.1.1 to 7.1.2
- [Release notes](https://github.com/astral-sh/setup-uv/releases)
- [Commits](astral-sh/setup-uv@2ddd2b9...8585678)

Updates `github/codeql-action` from 4.30.9 to 4.31.0
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](github/codeql-action@16140ae...4e94bd1)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-version: 5.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
  dependency-group: github_actions
- dependency-name: actions/download-artifact
  dependency-version: 6.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
  dependency-group: github_actions
- dependency-name: astral-sh/setup-uv
  dependency-version: 7.1.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: github_actions
- dependency-name: github/codeql-action
  dependency-version: 4.31.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: github_actions
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Timothy Pansino <[email protected]>
@hmstepanek hmstepanek force-pushed the partial-granularity-type-support branch from f29653a to edbfd79 Compare October 27, 2025 23:49
@hmstepanek hmstepanek requested a review from lrafeei October 28, 2025 22:30

application_settings.attribute_filter = AttributeFilter(flatten_settings(application_settings))

simplify_distributed_tracing_sampler_granularity_settings(application_settings)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I just realized that simplify_distributed_tracing_sampler_granularity_settings() should either

  1. be moved before the attribute_filter application, but right after apply_server_side_settings()
  2. be removed all together and put the logic from that function in apply_server_side_settings() (maybe after the custom_insights_events.max_attribute_value override?)

@hmstepanek hmstepanek requested a review from lrafeei October 30, 2025 20:35

application_settings.attribute_filter = AttributeFilter(flatten_settings(application_settings))

simplify_distributed_tracing_sampler_granularity_settings(application_settings)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since the logic for this has now moved to apply_server_side_settings(), the call to this function can be removed

@hmstepanek hmstepanek force-pushed the partial-granularity-type-support branch from 1f241ed to d16d5dc Compare October 30, 2025 21:00
@hmstepanek hmstepanek force-pushed the partial-granularity-type-support branch from 80d39d5 to 9c14833 Compare October 30, 2025 21:04
hmstepanek and others added 11 commits October 30, 2025 21:07
Bumps the github_actions group with 1 update: [github/codeql-action](https://github.com/github/codeql-action).


Updates `github/codeql-action` from 4.31.0 to 4.31.2
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](github/codeql-action@4e94bd1...0499de3)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-version: 4.31.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: github_actions
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* Modify extractor logic.

* Add support for Claude Sonnet 3+ and region aware models.

* Update claude content extraction logic.

* Add support for Claude Sonnet 3+ and region aware models.

* Update claude content extraction logic.

* Add testing for aiobotocore.

* Restore newline.

---------

Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
* Enable env vars for attribute filters

* [MegaLinter] Apply linters fixes

* Trigger tests

* Change attribute filters to space delimited

* Fix test assertion

---------

Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Co-authored-by: Tim Pansino <[email protected]>
Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

tests-failing Tests failing in CI.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants