René's URL Explorer Experiment


Title: Counter name/type inference changed in 1.6.1 for untyped metrics, breaking downstream expectation of UNKNOWN · Issue #2087 · prometheus/client_java · GitHub

Open Graph Title: Counter name/type inference changed in 1.6.1 for untyped metrics, breaking downstream expectation of UNKNOWN · Issue #2087 · prometheus/client_java

X Title: Counter name/type inference changed in 1.6.1 for untyped metrics, breaking downstream expectation of UNKNOWN · Issue #2087 · prometheus/client_java

Description: Summary After upgrading The JMX Exporter from 1.5.1 to 1.6.1, a metric that was previously discoverable as an untyped/unknown metric is now exposed as a counter with a _total suffix. This appears to change behavior for metrics where the ...

Open Graph Description: Summary After upgrading The JMX Exporter from 1.5.1 to 1.6.1, a metric that was previously discoverable as an untyped/unknown metric is now exposed as a counter with a _total suffix. This appears t...

X Description: Summary After upgrading The JMX Exporter from 1.5.1 to 1.6.1, a metric that was previously discoverable as an untyped/unknown metric is now exposed as a counter with a _total suffix. This appears t...

Opengraph URL: https://github.com/prometheus/client_java/issues/2087

X: @github

direct link

Domain: github.com


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Counter name/type inference changed in 1.6.1 for untyped metrics, breaking downstream expectation of UNKNOWN","articleBody":"## Summary\n\nAfter upgrading The JMX Exporter from `1.5.1` to `1.6.1`, a metric that was previously discoverable as an untyped/unknown metric is now exposed as a counter with a `_total` suffix.\n\nThis appears to change behavior for metrics where the downstream library did **not** explicitly configure the type, and only optionally supports its own local heuristic for inferring counters from names.\n\n## Why this matters\n\nJMX Exporter supports this config option:\n\n- `inferCounterTypeFromName: true|false`\n\nExpected behavior from the JMX Exporter perspective:\n\n- when `inferCounterTypeFromName: false`, metrics without an explicit configured type should remain `UNKNOWN`\n- when `inferCounterTypeFromName: true`, names ending in `_total` may be treated as counters\n\nAfter upgrading to `client_java 1.6.1`, it looks like `client_java` is applying counter naming/type behavior in a way that changes the effective metric identity for downstream code inspecting registry output.\n\n## Observed behavior\n\nA generated metric based on JMX rule output is looked up under the name:\n\n- `kafka_consumer_request`\n\nWith `1.6.1`, the actual scraped metric is:\n\n- `kafka_consumer_request_total`\n\nand it is exposed as a counter snapshot.\n\nIn other words, the same logical downstream metric appears to have shifted from:\n\n- unknown/untyped metric identity: `kafka_consumer_request`\n\nto:\n\n- counter metric identity: `kafka_consumer_request_total`\n\n## Why this looks like a regression\n\nFrom the downstream library’s perspective, there is an important distinction between:\n\n1. **explicit or locally inferred metric type**, and\n2. **Prometheus naming normalization**\n\nIf the downstream library does **not** set type to counter, we would expect the metric to remain `UNKNOWN`.\n\nIf `client_java` now turns an untyped metric into counter-style exported identity purely because of naming rules, that seems to bypass downstream type semantics.\n\nThis is especially concerning for the equivalent of our `inferCounterTypeFromName: false` case, where the downstream library is explicitly saying “do not infer counter type from name”.\n\n## Reproduction shape\n\nUsing JMX Exporter-style logic, a rule generates a metric name from an attribute like `request-total`, resulting in a base metric name around:\n\n- `kafka_consumer_request`\n\nThere is no explicit configured type in the rule.\n\nExpected with local inference disabled:\n- metric remains `UNKNOWN`\n- metric remains discoverable as `kafka_consumer_request`\n\nObserved in `1.6.1`:\n- metric is exposed as `kafka_consumer_request_total`\n- metric is a counter snapshot\n\n## Impact\n\nThis breaks downstream tests and exact-name registry inspection logic, even though the downstream library did not explicitly opt into counter typing in the affected case.\n","author":{"url":"https://github.com/dhoard","@type":"Person","name":"dhoard"},"datePublished":"2026-05-01T18:43:16Z","url":"https://github.com/prometheus/client_java/issues/2087"}

react-profiling0
react-import-mapreact,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322
route-pattern/_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format)
route-controllervoltron_issues_fragments
route-actionissue_layout
fetch-noncev2:9e48565c-a7af-08ec-e7a5-90667dcb7d6d
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-idB63A:85870:62FC0:8A3FC:6AFBB671
html-safe-noncedbdc41e33887e7b00a4a98d2dd74ae41d9aff0c0663cc40096e4755d292c3a7a
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCNjNBOjg1ODcwOjYyRkMwOjhBM0ZDOjZBRkJCNjcxIiwidmlzaXRvcl9pZCI6IjYyNzg1NjM4NjI4ODY5ODczNzciLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ==
visitor-hmac0c305744a0bebd0a5010e7ce6e503255073b86c68e12e762edc8ea78088bc24d
hovercard-subject-tagissue:4366078547
github-keyboard-shortcutsrepository,issues,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/issues_fragments/issue_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/prometheus/client_java/2087/issue_layout
twitter:imagehttps://opengraph.githubassets.com/96f047fb87ab1397786e43658cedb4d4bb4eda6ed2736f175010295fc0e4e9d6/prometheus/client_java/issues/2087
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/96f047fb87ab1397786e43658cedb4d4bb4eda6ed2736f175010295fc0e4e9d6/prometheus/client_java/issues/2087
og:image:altSummary After upgrading The JMX Exporter from 1.5.1 to 1.6.1, a metric that was previously discoverable as an untyped/unknown metric is now exposed as a counter with a _total suffix. This appears t...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernamedhoard
hostnamegithub.com
expected-hostnamegithub.com
None2b2ef9c1578c18d8ed27027940544c958743213cf4461659f14d3ccdf51e162c
turbo-cache-controlno-preview
go-importgithub.com/prometheus/client_java git https://github.com/prometheus/client_java.git
octolytics-dimension-user_id3380462
octolytics-dimension-user_loginprometheus
octolytics-dimension-repository_id7997879
octolytics-dimension-repository_nwoprometheus/client_java
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id7997879
octolytics-dimension-repository_network_root_nwoprometheus/client_java
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
releasee4cce0e99cf61481a318ff12c2e8580153a6c7c6
ui-targetfull
theme-color#1e2327
color-schemelight dark
react-app-nameissues

Links:

Skip to contenthttps://github.com/prometheus/client_java/issues/2087#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fprometheus%2Fclient_java%2Fissues%2F2087
GitHubRepository hosting, code review, and collaborationhttps://github.com/platform
CopilotAI coding agent for tasks, projects, and automated workhttps://github.com/features/copilot
ActionsCI/CD and automationhttps://github.com/features/actions
Code QualityQuality analysis, fixes, and enforcementhttps://github.com/features/code-quality
CodespacesCloud development environmentshttps://github.com/features/codespaces
Code SecurityVulnerability detection and remediationhttps://github.com/security/advanced-security/code-security
Secret ProtectionSecret scanning and leak preventionhttps://github.com/security/advanced-security/secret-protection
All Featureshttps://github.com/features
Documentationhttps://docs.github.com/en
Traininghttps://learn.github.com/skills
Certificationshttps://learn.github.com/credentials
Build with Copilothttps://github.com/features/ai
Customize Copilothttps://docs.github.com/en/copilot/how-tos/copilot-on-github/customize-copilot/customize-copilot-overview
Integrationshttps://github.com/marketplace
Trending reposhttps://github.com/trending
GitHub Sponsorshttps://github.com/open-source/sponsors
Developer articleshttps://github.com/resources/articles
ChangelogYour source for the latest features, improvements, and fixes across GitHub products, all in one place.https://github.blog/changelog/
Enterpriseshttps://github.com/enterprise
Teamhttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
See all industrieshttps://github.com/solutions/industry
Why GitHubhttps://github.com/why-github
Customer Storieshttps://github.com/customer-stories
Business insightshttps://github.com/solutions/executive-insights
Trust Centerhttps://github.com/trust-center
GitHub Advanced SecurityEnterprise-grade code securityhttps://github.com/security/advanced-security
Copilot for businessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Documentationhttps://docs.github.com/en
Resource centerhttps://github.com/resources
Bloghttps://github.blog/
Events & webinarshttps://github.com/resources/events
Community Forumhttps://github.com/orgs/community/discussions
Customer Storieshttps://github.com/customer-stories
Integrationshttps://github.com/marketplace
Customer supporthttps://help.github.com/
Traininghttps://learn.github.com/skills
GitHub Statushttps://www.githubstatus.com/
Abouthttps://github.com/about
Partnershttps://github.com/partners
Changeloghttps://github.blog/changelog/
GitHub UniverseThe event for developers, by developers — talks, workshops, and what’s next for GitHub.https://githubuniverse.com/
Pricinghttps://github.com/pricing
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fprometheus%2Fclient_java%2Fissues%2F2087
Sign uphttps://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fissues_fragments%2Fissue_layout&source=header-repo&source_repo=prometheus%2Fclient_java
Reloadhttps://github.com/prometheus/client_java/issues/2087
Reloadhttps://github.com/prometheus/client_java/issues/2087
Reloadhttps://github.com/prometheus/client_java/issues/2087
prometheushttps://github.com/prometheus
client_javahttps://github.com/prometheus/client_java
Codehttps://github.com/prometheus/client_java
Issues12 (12)https://github.com/prometheus/client_java/issues
Pull requests18 (18)https://github.com/prometheus/client_java/pulls
Actionshttps://github.com/prometheus/client_java/actions
Projectshttps://github.com/prometheus/client_java/projects
Security and qualityhttps://github.com/prometheus/client_java/security
Insightshttps://github.com/prometheus/client_java/pulse
https://github.com/prometheus/client_java
New issuehttps://github.com/login?return_to=https://github.com/prometheus/client_java/issues/2087
New issuehttps://github.com/login?return_to=https://github.com/prometheus/client_java/issues/2087
#2124https://github.com/prometheus/client_java/pull/2124
Counter name/type inference changed in 1.6.1 for untyped metrics, breaking downstream expectation of UNKNOWNhttps://github.com/prometheus/client_java/issues/2087#top
#2124https://github.com/prometheus/client_java/pull/2124
https://github.com/zeitlinger
https://github.com/jaydeluca
https://github.com/copilot-swe-agent
https://github.com/dhoard
dhoardhttps://github.com/dhoard
on May 1, 2026https://github.com/prometheus/client_java/issues/2087#issue-4366078547
dhoardhttps://github.com/dhoard
jaydelucahttps://github.com/jaydeluca
zeitlingerhttps://github.com/zeitlinger
on May 1, 2026https://github.com/prometheus/client_java/issues/2087#event-25079351501
jaydelucahttps://github.com/jaydeluca
Copilothttps://github.com/apps/copilot-swe-agent
on May 4, 2026https://github.com/prometheus/client_java/issues/2087#event-25131068055
Copilothttps://github.com/apps/copilot-swe-agent
fix: restore reserved suffix stripping in `PrometheusNaming.sanitizeMetricName()` #2094https://github.com/prometheus/client_java/pull/2094
on May 4, 2026https://github.com/prometheus/client_java/issues/2087#event-25131073147
zeitlingerhttps://github.com/zeitlinger
completedhttps://github.com/prometheus/client_java/issues?q=is%3Aissue%20state%3Aclosed%20archived%3Afalse%20reason%3Acompleted
#2124https://github.com/prometheus/client_java/pull/2124
on May 20, 2026https://github.com/prometheus/client_java/issues/2087#event-25750517796
zeitlingerhttps://github.com/zeitlinger
on May 20, 2026https://github.com/prometheus/client_java/issues/2087#event-25750529198
fix: restore reserved suffix stripping in `PrometheusNaming.sanitizeM…https://github.com/zeitlinger/client_java/commit/2d0f508efd2f5e009b6f09f6a9ccb451cf9f3b6f
2d0f508https://github.com/zeitlinger/client_java/commit/2d0f508efd2f5e009b6f09f6a9ccb451cf9f3b6f
jaydelucahttps://github.com/jaydeluca
on Jun 4, 2026https://github.com/prometheus/client_java/issues/2087#event-26352906497
fix: restore reserved suffix stripping in `PrometheusNaming.sanitizeM…https://github.com/prometheus/client_java/commit/c89e6b5faa75e0ce5f7e82325dfcb397af1daa77
c89e6b5https://github.com/prometheus/client_java/commit/c89e6b5faa75e0ce5f7e82325dfcb397af1daa77
Sign up for freehttps://github.com/signup?return_to=https://github.com/prometheus/client_java/issues/2087
Sign in to commenthttps://github.com/login?return_to=https://github.com/prometheus/client_java/issues/2087
Copilothttps://github.com/apps/copilot-swe-agent
jaydelucahttps://github.com/jaydeluca
zeitlingerhttps://github.com/zeitlinger
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.