Skip to content

Human friendly endpoint table#879

Open
wanyunSu wants to merge 2 commits intodevelopfrom
wanyunSu/endpoint-hostname-fix
Open

Human friendly endpoint table#879
wanyunSu wants to merge 2 commits intodevelopfrom
wanyunSu/endpoint-hostname-fix

Conversation

@wanyunSu
Copy link
Copy Markdown
Contributor

@wanyunSu wanyunSu commented Apr 15, 2026

Description

Fixes issue #792 #859

The status table now shows both user-friendly hostname and the actual endpoints that applications connect to:

K8s session:

drunc-unified-shell > status
                                                 claudia-k8s-ehn1-test status                                                  
┏━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━┳━━━━━━━━━┳━━━━━━━━━━┳━━━━━━━━━━┳━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
┃ Name                   ┃ Info ┃ State   ┃ Substate ┃ In error ┃ Included ┃ Endpoint                                         ┃
┡━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━╇━━━━━━━━━╇━━━━━━━━━━╇━━━━━━━━━━╇━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┩
│ root-controller        │      │ initial │ initial  │ No       │ Yes      │ grpc://np04-srv-019:30006 (actual: 10.244.21.58) │
│   df-controller        │      │ initial │ initial  │ No       │ Yes      │ grpc://np04-srv-019:38701 (actual: 10.73.136.38) │
│     df-01              │      │ initial │ idle     │ No       │ Yes      │ rest://np04-srv-019:44067 (actual: 10.73.136.38) │
│     dfo-01             │      │ initial │ idle     │ No       │ Yes      │ rest://np04-srv-019:49895 (actual: 10.73.136.38) │
│     tp-stream-writer   │      │ initial │ idle     │ No       │ Yes      │ rest://np04-srv-019:60739 (actual: 10.73.136.38) │
│   hsi-fake-controller  │      │ initial │ initial  │ No       │ Yes      │ grpc://np04-srv-019:40771 (actual: 10.73.136.38) │
│     hsi-fake-01        │      │ initial │ idle     │ No       │ Yes      │ rest://np04-srv-019:44305 (actual: 10.73.136.38) │
│     hsi-fake-to-tc-app │      │ initial │ idle     │ No       │ Yes      │ rest://np04-srv-019:55657 (actual: 10.73.136.38) │
│   ru-controller        │      │ initial │ initial  │ No       │ Yes      │ grpc://np04-srv-019:36865 (actual: 10.73.136.38) │
│     ru-01              │      │ initial │ idle     │ No       │ Yes      │ rest://np04-srv-019:60167 (actual: 10.73.136.38) │
│   trg-controller       │      │ initial │ initial  │ No       │ Yes      │ grpc://np04-srv-019:45467 (actual: 10.73.136.38) │
│     mlt                │      │ initial │ idle     │ No       │ Yes      │ rest://np04-srv-019:50567 (actual: 10.73.136.38) │
│     tc-maker-1         │      │ initial │ idle     │ No       │ Yes      │ rest://np04-srv-019:36751 (actual: 10.73.136.38) │
└────────────────────────┴──────┴─────────┴──────────┴──────────┴──────────┴──────────────────────────────────────────────────┘
[2026/04/15 09:52:20 UTC] INFO       shell_utils.py:165                       drunc.utils.ShellContext                           Current 
FSM status is initial. Available transitions are conf. Available sequence commands are start-run.
drunc-unified-shell > conf
[2026/04/15 09:52:22 UTC] INFO       shell_utils.py:552                       drunc.controller.iface.shell_utils                 Running 
transition 'conf' on controller 'root-controller', targeting: 'root-controller'
                                                    claudia-k8s-ehn1-test status                                                    
┏━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━┳━━━━━━━━━━━━┳━━━━━━━━━━━━┳━━━━━━━━━━┳━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
┃ Name                   ┃ Info ┃ State      ┃ Substate   ┃ In error ┃ Included ┃ Endpoint                                         ┃
┡━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━╇━━━━━━━━━━━━╇━━━━━━━━━━━━╇━━━━━━━━━━╇━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┩
│ root-controller        │      │ configured │ configured │ No       │ Yes      │ grpc://np04-srv-019:30006 (actual: 10.244.21.58) │
│   df-controller        │      │ configured │ configured │ No       │ Yes      │ grpc://np04-srv-019:38701 (actual: 10.73.136.38) │
│     df-01              │      │ configured │ idle       │ No       │ Yes      │ rest://np04-srv-019:44067 (actual: 10.73.136.38) │
│     dfo-01             │      │ configured │ idle       │ No       │ Yes      │ rest://np04-srv-019:49895 (actual: 10.73.136.38) │
│     tp-stream-writer   │      │ configured │ idle       │ No       │ Yes      │ rest://np04-srv-019:60739 (actual: 10.73.136.38) │
│   hsi-fake-controller  │      │ configured │ configured │ No       │ Yes      │ grpc://np04-srv-019:40771 (actual: 10.73.136.38) │
│     hsi-fake-01        │      │ configured │ idle       │ No       │ Yes      │ rest://np04-srv-019:44305 (actual: 10.73.136.38) │
│     hsi-fake-to-tc-app │      │ configured │ idle       │ No       │ Yes      │ rest://np04-srv-019:55657 (actual: 10.73.136.38) │
│   ru-controller        │      │ configured │ configured │ No       │ Yes      │ grpc://np04-srv-019:36865 (actual: 10.73.136.38) │
│     ru-01              │      │ configured │ idle       │ No       │ Yes      │ rest://np04-srv-019:60167 (actual: 10.73.136.38) │
│   trg-controller       │      │ configured │ configured │ No       │ Yes      │ grpc://np04-srv-019:45467 (actual: 10.73.136.38) │
│     mlt                │      │ configured │ idle       │ No       │ Yes      │ rest://np04-srv-019:50567 (actual: 10.73.136.38) │
│     tc-maker-1         │      │ configured │ idle       │ No       │ Yes      │ rest://np04-srv-019:36751 (actual: 10.73.136.38) │
└────────────────────────┴──────┴────────────┴────────────┴──────────┴──────────┴──────────────────────────────────────────────────┘
Waiting for conf to complete... ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━   0% -:--:--
                            conf execution report                             
┏━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
┃ Name                   ┃ Command execution     ┃ FSM transition            ┃
┡━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━━━━┩
│ root-controller        │ Executed Successfully │ Fsm Executed Successfully │
│   df-controller        │ Executed Successfully │ Fsm Executed Successfully │
│     df-01              │ Executed Successfully │ Fsm Executed Successfully │
│     dfo-01             │ Executed Successfully │ Fsm Executed Successfully │
│     tp-stream-writer   │ Executed Successfully │ Fsm Executed Successfully │
│   hsi-fake-controller  │ Executed Successfully │ Fsm Executed Successfully │
│     hsi-fake-01        │ Executed Successfully │ Fsm Executed Successfully │
│     hsi-fake-to-tc-app │ Executed Successfully │ Fsm Executed Successfully │
│   ru-controller        │ Executed Successfully │ Fsm Executed Successfully │
│     ru-01              │ Executed Successfully │ Fsm Executed Successfully │
│   trg-controller       │ Executed Successfully │ Fsm Executed Successfully │
│     mlt                │ Executed Successfully │ Fsm Executed Successfully │
│     tc-maker-1         │ Executed Successfully │ Fsm Executed Successfully │
└────────────────────────┴───────────────────────┴───────────────────────────┘
                                                    claudia-k8s-ehn1-test status                                                    
┏━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━┳━━━━━━━━━━━━┳━━━━━━━━━━━━┳━━━━━━━━━━┳━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
┃ Name                   ┃ Info ┃ State      ┃ Substate   ┃ In error ┃ Included ┃ Endpoint                                         ┃
┡━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━╇━━━━━━━━━━━━╇━━━━━━━━━━━━╇━━━━━━━━━━╇━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┩
│ root-controller        │      │ configured │ configured │ No       │ Yes      │ grpc://np04-srv-019:30006 (actual: 10.244.21.58) │
│   df-controller        │      │ configured │ configured │ No       │ Yes      │ grpc://np04-srv-019:38701 (actual: 10.73.136.38) │
│     df-01              │      │ configured │ idle       │ No       │ Yes      │ rest://np04-srv-019:44067 (actual: 10.73.136.38) │
│     dfo-01             │      │ configured │ idle       │ No       │ Yes      │ rest://np04-srv-019:49895 (actual: 10.73.136.38) │
│     tp-stream-writer   │      │ configured │ idle       │ No       │ Yes      │ rest://np04-srv-019:60739 (actual: 10.73.136.38) │
│   hsi-fake-controller  │      │ configured │ configured │ No       │ Yes      │ grpc://np04-srv-019:40771 (actual: 10.73.136.38) │
│     hsi-fake-01        │      │ configured │ idle       │ No       │ Yes      │ rest://np04-srv-019:44305 (actual: 10.73.136.38) │
│     hsi-fake-to-tc-app │      │ configured │ idle       │ No       │ Yes      │ rest://np04-srv-019:55657 (actual: 10.73.136.38) │
│   ru-controller        │      │ configured │ configured │ No       │ Yes      │ grpc://np04-srv-019:36865 (actual: 10.73.136.38) │
│     ru-01              │      │ configured │ idle       │ No       │ Yes      │ rest://np04-srv-019:60167 (actual: 10.73.136.38) │
│   trg-controller       │      │ configured │ configured │ No       │ Yes      │ grpc://np04-srv-019:45467 (actual: 10.73.136.38) │
│     mlt                │      │ configured │ idle       │ No       │ Yes      │ rest://np04-srv-019:50567 (actual: 10.73.136.38) │
│     tc-maker-1         │      │ configured │ idle       │ No       │ Yes      │ rest://np04-srv-019:36751 (actual: 10.73.136.38) │
└────────────────────────┴──────┴────────────┴────────────┴──────────┴──────────┴──────────────────────────────────────────────────┘
[2026/04/15 09:52:22 UTC] INFO       shell_utils.py:165                       drunc.utils.ShellContext                           Current 
FSM status is configured. Available transitions are start, scrap. Available sequence commands are shutdown, start-run.

and in SSH session:

                                                     claudia-ssh status                                                     
┏━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━┳━━━━━━━━━┳━━━━━━━━━━┳━━━━━━━━━━┳━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
┃ Name                   ┃ Info ┃ State   ┃ Substate ┃ In error ┃ Included ┃ Endpoint                                      ┃
┡━━━━━━━━━━━━━━━━━━━━━━━━╇━━━━━━╇━━━━━━━━━╇━━━━━━━━━━╇━━━━━━━━━━╇━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┩
│ root-controller        │      │ initial │ initial  │ No       │ Yes      │ grpc://localhost:30006 (actual: 10.73.136.38) │
│   df-controller        │      │ initial │ initial  │ No       │ Yes      │ grpc://localhost:33561 (actual: 10.73.136.38) │
│     df-01              │      │ initial │ idle     │ No       │ Yes      │ rest://localhost:57267 (actual: 10.73.136.38) │
│     dfo-01             │      │ initial │ idle     │ No       │ Yes      │ rest://localhost:50557 (actual: 10.73.136.38) │
│     tp-stream-writer   │      │ initial │ idle     │ No       │ Yes      │ rest://localhost:59713 (actual: 10.73.136.38) │
│   hsi-fake-controller  │      │ initial │ initial  │ No       │ Yes      │ grpc://localhost:35701 (actual: 10.73.136.38) │
│     hsi-fake-01        │      │ initial │ idle     │ No       │ Yes      │ rest://localhost:40095 (actual: 10.73.136.38) │
│     hsi-fake-to-tc-app │      │ initial │ idle     │ No       │ Yes      │ rest://localhost:47477 (actual: 10.73.136.38) │
│   ru-controller        │      │ initial │ initial  │ No       │ Yes      │ grpc://localhost:34525 (actual: 10.73.136.38) │
│     ru-01              │      │ initial │ idle     │ No       │ Yes      │ rest://localhost:35873 (actual: 10.73.136.38) │
│   trg-controller       │      │ initial │ initial  │ No       │ Yes      │ grpc://localhost:34503 (actual: 10.73.136.38) │
│     mlt                │      │ initial │ idle     │ No       │ Yes      │ rest://localhost:59025 (actual: 10.73.136.38) │
│     tc-maker-1         │      │ initial │ idle     │ No       │ Yes      │ rest://localhost:60825 (actual: 10.73.136.38) │
└────────────────────────┴──────┴─────────┴──────────┴──────────┴──────────┴───────────────────────────────────────────────┘

Type of change

  • New feature / enhancement
  • Optimization
  • Bug fix
  • Breaking change
  • Documentation

List of required branches from other repositories

n/a

Change log

Add a helper function get_endpoint_display_host_overrides to improve the readability of the controller status table display by replacing raw endpoint IPs with human-readable hostnames when available.

Note it only overrides the table when a Process Manager is available, the mapping is populated from ProcessDescription.metadata.hostname
This allows Kubernetes node names (or other host metadata) to be used for display.
The default implementation returns {} (no overrides).

The change is purely cosmetic and should not affect connectivity or controller behaviour.

Suggested manual testing checklist

LIST COMMANDS TO DEMONSTRATE CHANGE

Developer checklist

Prior to marking this as "Ready for Review"

Tests ran on: np04 019, with NFD_DEV_260414_A9

Unit tests - some tests can't be ran on the CI. This is documented. If this PR checks a feature that can't be tested with CI, this has been marked appropriately.

Integration tests - the daqsystemtest_integtest_bundle requires a lot of resources, and connections to the EHN1 infrastructure. Check the cross referenced list if you can't run these. The developer needs to run at least the .

  • Unit tests (pytest --marker) passed
    • With relevant marker
    • Without marker
  • Integration tests passed
    • Only daqsystemtest_integtest_bundle.sh -k minimal_system_quick_test.py
    • Full daqsystemtest_integtest_bundle.sh
  • Testing skipped as there are no core code changes in this PR, this only relates to documentation/CI workflows

Final checklist prior to marking this as "Ready for Review"

  • Code is clearly commented.
  • New unit tests have been added, or is documented in # ISSUE NUMBER
  • A suitable reviewer has been chosen from this list.

Reviewer checklist

  • This branch has been rebased with develop prior to testing.
  • Suggested manual tests show changes.
  • CI workflows fails documented (if present)
  • Integration tests passed
    • Only concern yourself if failures related to drunc are in the log files
    • If non-drunc failure appears:
      • Validate failure in fresh working area
      • Contact Pawel if unsure

Once the features are validated and both the unit and integration tests pass, the PRs is ready to be merged.

Prior to merging

Choose one of the following an complete all substeps
  • Changes only affect the Run Control, are in a single repository, and do not affect the end user.
    • Changes are documented in docstrings and code comments
    • Wiki has been updated if architectural or endpoint changes
  • Otherwise
    • Workflow changes demonstrated in the Change Log (if necessary)
    • Wiki has been updated (if necessary)
    • #daq-sw-librarians Slack channel notified (see below)

Once completed, the reviewer can merge the PR.

Notification message for a Slack channel

Note - this should be to #dunedaq-integration for general workflow that isn't during a release candidate period, and to #daq-release-prep otherwise.

For an single merge that changes the user workflow

The CCM WG has an isolated PR ready to merge that affects user workflows. The PR is:

_URL_

I will leave time for any comments, otherwise will merge these at the end of the work day _Insert your time zone_.

For co-ordinated merge

The CCM WG has a set of co-ordinated merges ready to merge. The PRs are:

_URL_

_URL_


I will leave time for any comments, otherwise will merge these at the end of the day.

@wanyunSu wanyunSu self-assigned this Apr 15, 2026
@wanyunSu wanyunSu mentioned this pull request Apr 15, 2026
22 tasks
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.

2 participants