lablup / lablup/backend.ai

Adapt gql_legacy domain resolvers to ASE-backed registry data

Open
#11,665 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
670
Forks
183
Avg merge
15h 13m
Merged PRs (30d)
368

Description

## Description

Keep the graphene schema in `api/gql_legacy/domain.py` unchanged (still `List[String]` of names). Update the resolver internals so that inputs are translated to registry UUIDs before reaching the dual-write path, and outputs are sourced from ASE so they never go stale.

## Scope

- No schema changes in `api/gql_legacy/domain.py` (lines 153 / 372 / 453 / 552 / 640 / 671).
- Inputs: `allowed_docker_registries` (name list) is resolved to a UUID list at the resolver boundary using `container_registries`; ambiguous names fan out to all matching UUIDs (current behavior preserved, no server crash).
- Outputs: the name list returned to clients is computed from ASE + `container_registries.name`, not from the (now possibly stale) ARRAY column.
- Same treatment applies to the gql_legacy SDK and CLI surfaces (`client/func/domain.py`, `client/cli/admin/domain.py`) — no signature changes; they continue to talk to the unchanged graphene schema.

## Success Criteria

- Graphene schema diff is empty for this field (mutation inputs and query outputs).
- Ambiguous-name input does not crash the server and ends up mapped to all matching registries.
- Returned name list always matches the current ASE state, even if the ARRAY column drifts.
- Existing graphene clients (including the legacy WebUI build) continue to work.
- pants test passes.

JIRA Issue: BA-6089

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.