Skip to content

declarative config metrics delta#1062

Merged
SylvainJuge merged 5 commits intoelastic:mainfrom
SylvainJuge:declarative-config-metric-temporality
Apr 22, 2026
Merged

declarative config metrics delta#1062
SylvainJuge merged 5 commits intoelastic:mainfrom
SylvainJuge:declarative-config-metric-temporality

Conversation

@SylvainJuge
Copy link
Copy Markdown
Member

@SylvainJuge SylvainJuge commented Apr 21, 2026

part of #1054

replaces #1058

@github-actions
Copy link
Copy Markdown

📋 Changelog

⚠️ Cannot generate changelog: no matching type label found on this PR.

🔖 Add one of these type labels to your PR:

Label Type
breaking-change breaking-change
bug bug-fix
deprecation deprecation
feature feature
enhancement enhancement
changelog:upstream-update enhancement
docs docs
documentation docs

🔖 To skip changelog generation or configure label rules, see docs/changelog.yml.

@@ -60,15 +60,17 @@ static void afterAll() {
@Test
void tomcat() {
target =
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

[for reviewer] this (and below) a test refactor to use builder pattern to make test slightly more readable/maintainable.

@SylvainJuge SylvainJuge marked this pull request as ready for review April 22, 2026 05:37
@SylvainJuge SylvainJuge requested a review from a team as a code owner April 22, 2026 05:37
@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Apr 22, 2026

Warning

Rate limit exceeded

@SylvainJuge has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 41 minutes and 42 seconds before requesting another review.

Your organization is not enrolled in usage-based pricing. Contact your admin to enable usage-based pricing to continue reviews beyond the rate limit, or try again in 41 minutes and 42 seconds.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: bad8cd66-9cca-442e-a605-2e1aed753373

📥 Commits

Reviewing files that changed from the base of the PR and between 4a836b2 and 89a79c8.

📒 Files selected for processing (1)
  • custom/src/main/resources/co/elastic/otel/config.yaml
📝 Walkthrough

Walkthrough

Configuration updates set temporality_preference: delta for the OTLP/HTTP metrics exporter, add a commented temporality_preference: delta entry for the disabled OTLP/gRPC exporter, and change the Java runtime telemetry emit_experimental_metrics/development value to an environment-driven boolean. A unit test now asserts the new temporality_preference JSON property. Smoke tests refactor container startup: the protected startTarget(...) was replaced by a public fluent TestTarget builder (testTarget(image)) with customize(...), withBaseEnvironmentVariables(...), and start(); test usages were updated accordingly.

🚥 Pre-merge checks | ✅ 2
✅ Passed checks (2 passed)
Check name Status Explanation
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • 🛠️ Update Documentation: Commit on current branch
  • 🛠️ Update Documentation: Create PR

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@custom/src/main/resources/co/elastic/otel/config.yaml`:
- Around line 47-55: The temporality_preference under the otlp_http exporter is
hard-coded to "delta"; change it to read from the
OTEL_EXPORTER_OTLP_METRICS_TEMPORALITY_PREFERENCE environment variable with a
default of "delta" (same ${VAR:-default} pattern used for endpoint and
headers_list) so users can override temporality to "cumulative" or "lowmemory";
update the temporality_preference setting in the otlp_http block accordingly.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: ec6c6c21-6e1b-4559-b4bd-95cdd968c1c0

📥 Commits

Reviewing files that changed from the base of the PR and between 04bb692 and 212ca78.

📒 Files selected for processing (5)
  • custom/src/main/resources/co/elastic/otel/config.yaml
  • custom/src/test/java/co/elastic/otel/declarativeconfig/DefaultDeclarativeConfigTest.java
  • smoke-tests/src/test/java/com/example/javaagent/smoketest/AppServerProvidersTest.java
  • smoke-tests/src/test/java/com/example/javaagent/smoketest/SmokeTest.java
  • smoke-tests/src/test/java/com/example/javaagent/smoketest/TestAppSmokeTest.java

Comment thread custom/src/main/resources/co/elastic/otel/config.yaml Outdated
Comment thread custom/src/main/resources/co/elastic/otel/config.yaml Outdated
@SylvainJuge SylvainJuge merged commit 108dbd6 into elastic:main Apr 22, 2026
21 checks passed
@SylvainJuge SylvainJuge deleted the declarative-config-metric-temporality branch April 22, 2026 13:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants