Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added feature: UUID obfuscation in URI label with URI_METRICS_DETAILED enabled #123

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

comemaryvallee
Copy link

Motivation

Monitor metrics per realms without constraint of high cardinality due to the presence of UUIDs in the URI label.

What

Added the option to replace user's or client's UUID value in the URI label to a generic {id} value even when the URI_METRICS_DETAILED system variable is set to true.

Why

Needed to be able to monitor metrics with the realm name value present in the URI label but without UUIDs values, due to its high cardinality. The keycloak-metrics-spi evolution added the obfuscation of UUIDs only with the obfuscation of realm name value.

How

By adding a check for a URI_METRICS_UUID_HIDED system variable set to true & by adding "users" value to the condition of UUID obfuscation.

Checklist:

  • Code has been tested locally by PR requester
  • Changes have been successfully verified by another team member

Additional Notes

Modified the README.md to add the description of this feature.

@pb82
Copy link
Contributor

pb82 commented Jan 11, 2022

thanks @comemaryvallee, that seems very useful. It reduces cardinality but also avoids leaking UUIDs. Is this something you're also interested in @CathalOConnorRH ?

@CathalOConnorRH
Copy link
Contributor

thanks @comemaryvallee, that seems very useful. It reduces cardinality but also avoids leaking UUIDs. Is this something you're also interested in @CathalOConnorRH ?

Hey @pb82 This might be something we could use alright, let me know if you would like me to test this change.

@MaksymAtVgs
Copy link

@CathalOConnorRH I'm interested in this changes too, any chances that this PR get merged to the master? And when is the next release expected?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants