BUG: Cluster screen "Remove node" sends DELETE to wrong URL — /cluster/nodes/:id vs server /:id #83
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Description
The Cluster screen's "Remove node" button sends a
DELETErequest to/api/v1/cluster/nodes/{nodeId}, but the server only registers a route atDELETE /api/v1/cluster/:id.Files:
services/web-ui/public/screens-admin.jsx(theremoveNodefunction calls/cluster/nodes/+ nodeId)services/mam-api/src/routes/cluster.jslinerouter.delete('/:id', ...)Requests:
DELETE /api/v1/cluster/nodes/{nodeId}DELETE /api/v1/cluster/{nodeId}The extra
/nodes/segment in the frontend path means Express never matches the route, returning a 404. The node is never deregistered.Impact: The "Remove node" button appears to do nothing (silent failure in the
catchhandler shows an alert: "Remove failed: 404 Not Found"). Nodes cannot be removed from the cluster screen.Suggested fix: Change the frontend call from
/cluster/nodes/${id}to/cluster/${id}, or add arouter.delete('/nodes/:id', ...)route incluster.jsthat delegates to the same handler.