ref(cache): [Cache Tracing 17] Move operation attribute to centralized CACHE_OPERATION_KEY#5206
Draft
adinauer wants to merge 1 commit intoref/cache-tracing-merge-startspan-helpersfrom
Draft
Conversation
…PERATION_KEY Replace local OPERATION_ATTRIBUTE constants in all cache wrappers with a shared CACHE_OPERATION_KEY constant in SpanDataConvention. Also changes the attribute key from "db.operation.name" to "cache.operation".
Contributor
Semver Impact of This PR🟢 Patch (bug fixes) 📋 Changelog PreviewThis is how your changes will appear in the changelog. This PR will not appear in the changelog. 🤖 This preview updates automatically when you update the PR. |
This was referenced Mar 18, 2026
Draft
fix(spring): [Cache Tracing 14] Fix cache hit detection for typed get and fix jcache docs link
#5203
Draft
Sentry Build Distribution
|
This was referenced Mar 18, 2026
Member
Author
|
@sentry review |
Member
Author
|
cursor review |
This was referenced Mar 18, 2026
Draft
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
PR Stack (Cache Tracing)
📜 Description
Replaces the local
OPERATION_ATTRIBUTE = "db.operation.name"constants in all four cache wrapper classes with a sharedCACHE_OPERATION_KEY = "cache.operation"constant inSpanDataConvention. Tests now also reference the constant instead of hardcoding the string.💡 Motivation and Context
The attribute key was duplicated across
SentryCacheWrapper(spring, spring-7, spring-jakarta) andSentryJCacheWrapper(jcache). Moving it toSpanDataConventionfollows the same pattern asCACHE_HIT_KEYandCACHE_KEY_KEY. Also renames fromdb.operation.nametocache.operationsince this is a cache attribute, not a database one.💚 How did you test it?
📝 Checklist
sendDefaultPIIis enabled.🔮 Next steps
#skip-changelog