Skip to content

Call v2 GetClusterIdentity, fall back to v1 on 404 - #689

Merged
ArnobKumarSaha merged 1 commit into
masterfrom
arnob-v2-identity
Nov 29, 2026
Merged

ArnobKumarSaha merged 1 commit into
masterfrom
arnob-v2-identity

Conversation

@ArnobKumarSaha

Copy link
Copy Markdown
Member

kube-ui-server v0.10.0 crash-loops against a platform in IAM v2_only mode: Identify calls GET /api/v1/clustersv2/identity/:uid, which v2_only does not mount (b3 routers/api/v1/testdata/routes.golden: M GET /v1/clustersv2/identity/:clusterID), so it gets 404 and the server exits.

  • Identify now calls the Connect procedure POST /api/v2/akp.cluster.v2.ClusterService/GetClusterIdentity ({"clusterUid": ...}) and maps {"identity": {...}} (protojson names: ownerId, managerId, hubClusterId, license.orgId) to kmapi.ClusterMetadata.
  • On 404 (platform without the v2 API) it falls back to the v1 route.
  • Connect, not REST (/api/v2/clusters/{uid}/identity), so it works whether or not b3's [rest] toggle is on.

Not covered: GetToken (/api/v1/agent/.../token) and audit register (/api/v1/register) are also v1-only routes in b3.

IAM v2_only platforms do not mount GET /api/v1/clustersv2/identity, so
Identify returned 404 and kube-ui-server exited at startup. Call the
akp.cluster.v2.ClusterService/GetClusterIdentity Connect procedure first
and use the v1 route only when the platform has no v2 API.

Signed-off-by: Arnob Kumar Saha <arnob@appscode.com>
Signed-off-by: Arnob kumar saha <arnob@appscode.com>
@ArnobKumarSaha
ArnobKumarSaha merged commit bb321f1 into master Nov 29, 2026
7 checks passed
@ArnobKumarSaha
ArnobKumarSaha deleted the arnob-v2-identity branch November 29, 2026 10:36
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.

1 participant