RockteMQ-AI commented on issue #1480:
URL:
https://github.com/apache/rocketmq-dashboard/issues/1480#issuecomment-5241457093
**Issue Evaluation**
Category: `bug` | Status: **Confirmed**
The reported issue has been verified against the current codebase.
**Root Cause:** In `frontend-new/src/pages/Cluster/cluster.jsx` (lines
56-84), the `useEffect` bootstrap calls `remoteApi.queryClusterList` with a
callback-style API but has no `finally` path:
1. `setLoading(false)` is only placed inside the callback body — if the
callback is never invoked (e.g., wrapper crash), the page spins forever.
2. The error branch shows a toast but does not clear `instances`,
`clusterNames`, or `allBrokersData` — stale data from a previous render can
persist.
3. No retry mechanism exists.
Note: The issue references `listInstances()` which doesn't exist by that
exact name — the actual call is `remoteApi.queryClusterList`. The underlying
pattern gap is real.
**Impact:** Cluster page (`cluster.jsx`) — users encountering network errors
or backend exceptions see a frozen spinner with no retry and no clear error
state.
**Severity:** Medium — the API wrapper's internal catch returns `{status:1}`
which surfaces a toast in common cases, but the missing `finally` guard, state
reset, and retry button are genuine gaps.
**Comparison:** `ClientInfoModal.jsx` (lines 29-49) correctly uses
`async/await` + `try/finally` — this page should follow the same pattern.
An automated fix proposal can be generated. Reply `/approve` to proceed with
PR generation.
---
*Automated evaluation by github-manager-bot*
--
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]