unbridled-41 opened a new pull request, #5948:
URL: https://github.com/apache/rocketmq-dashboard/pull/5948

   ### Which Issue(s) This PR Fixes
   
   Fixes #5947
   
   ### Problem / Evidence
   
   ```ts
   // BrokerCluster.mapClusters (before)
   nameServers.push({ ..., version: cluster.version, ... });
   proxies.push({ ..., version: cluster.version, ... });
   ```
   
   `NameServerInfo` is `{addr, status}` and `ProxyInfo` is `{addr, status, 
connections, grpcPort, remotingPort}` (docs/api-spec.md and 
`web/src/api/cluster.ts`); `ClusterVO.version` is not set on the discovery path 
either. The column therefore showed the mock's cluster version for every node 
in demo mode and a blank cell in production, and both tabs exported it as a 
`Version` CSV column:
   
   ```
   BrokerCluster: does not render a Version column for nameservers or proxies
   AssertionError: expected document not to contain element, found <th
   ```
   
   This is the sibling of the already-accepted removal of the fabricated 
NameServer Connections column (#5647 / 6c0e983d), which removed the field 
rather than populating it with a guess.
   
   ### Root cause / Fix
   
   A node-level column filled from the parent cluster object. Drop the field, 
the two columns and the two CSV entries; the Broker tab keeps its Version 
column, which comes from a real per-broker value (`BrokerVO.version`).
   
   ### Priority and scoring
   
   **PRIORITY 45** — impact 14/40 (a fabricated version in demo mode, an empty 
column in production, both exported), blast radius 10/20 (two of the three 
tabs), reproducibility 18/20 (deterministic, pinned by the new test), 
maintenance value 3/20.
   
   **FIX_CONFIDENCE 78** — the accepted precedent defines the remedy.
   
   ### Tests
   
   `cd web && npx vitest run src/pages/studio/__tests__/BrokerCluster.test.tsx` 
-> `Tests 17 passed`.
   
   | Test | Before | After |
   |---|---|---|
   | `does not render a Version column for nameservers or proxies` | FAIL 
(`found <th`) | PASS (also asserts the broker tab keeps its column) |
   | the existing connections-column case | PASS | PASS |
   
   `npx eslint` reports no errors; `npx tsc -b` passes.
   
   ### Risk
   
   Two table columns and two CSV columns disappear; nothing else read those 
values (grep: the field was only set in the mapping and read by those columns).


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to