HDDS-15351. Display datanode UUID in Datanode web UI#10357
Open
chihsuan wants to merge 3 commits into
Open
Conversation
sreejasahithi
approved these changes
May 27, 2026
Contributor
sreejasahithi
left a comment
There was a problem hiding this comment.
Thanks @chihsuan for this improvement
LGTM
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.
What changes were proposed in this pull request?
This PR makes the DataNode web UI display the DataNode UUID.
Some operational commands (e.g. decommission) require the DataNode UUID, but previously there was no easy way to look it up from the web UI. This change exposes the UUID through the DataNode's JMX MXBean and renders it on the DataNode overview page.
Changes:
DNMXBean/DNMXBeanImpl: add adatanodeUuidfield with a getter/setter, following the existinghostNamepattern. This exposes the UUID as the JMX attributeDatanodeUuid.HddsDatanodeService: during startup, set the UUID on the MXBean fromdatanodeDetails.getUuidString()(after the DataNode details are initialized, so the value is always present).overview.html(the shared framework overview template): add a Datanode UUID row, guarded byng-if="$ctrl.jmx.DatanodeUuid"so it only renders on the DataNode UI. SCM/OM do not expose that JMX attribute, so the row is hidden there.Note: the SCM web UI already shows the UUID (Node Status -> UUID column), so only the DataNode side needed changes here.
What is the link to the Apache JIRA
https://issues.apache.org/jira/browse/HDDS-15351
How was this patch tested?
Unit test: Added
TestHddsDatanodeService#testDatanodeUuidInMXBean, which starts the service, reads theDatanodeUuidattribute from the JMX MXBean, and asserts it matchesdatanodeDetails.getUuidString().Manual UI verification:
docker compose ps datanode # or compose v2: docker compose port --index 1 datanode 19864http://localhost:<mapped-port>). The overview table now shows the new row Datanode UUID.