Skip to content

internal/rest/resources/cluster: Return 404 when member not found in truststore - #751

Merged
roosterfish merged 1 commit into
canonical:v2from
claudiubelu:v2-return-404-member-not-found
Jun 11, 2026
Merged

internal/rest/resources/cluster: Return 404 when member not found in truststore#751
roosterfish merged 1 commit into
canonical:v2from
claudiubelu:v2-return-404-member-not-found

Conversation

@claudiubelu

Copy link
Copy Markdown
Contributor

clusterMemberDelete is returning a SmartError when the given member is absent from the truststore. This makes it difficult for callers to distinguish "not found" from a real internal error.

Switch to NotFound error, so callers can use IsNotFoundError to treat an already-absent member as a success.

…rors

clusterMemberDelete is returning a SmartError when the given member is absent
from the truststore. This makes it difficult for callers to distinguish "not found"
from a real internal error.

Switch to NotFound error, so callers can use IsNotFoundError to treat an
already-absent member as a success.

Additionally switched other client-related errors into BadRequest.

(cherry picked from commit b1b192d)
Signed-off-by: Claudiu Belu <cbelu@cloudbasesolutions.com>
@claudiubelu
claudiubelu force-pushed the v2-return-404-member-not-found branch from 7704c36 to f338236 Compare June 11, 2026 11:59
@roosterfish

Copy link
Copy Markdown
Contributor

Ty!

@roosterfish
roosterfish merged commit 936197c into canonical:v2 Jun 11, 2026
8 checks passed
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