feat: Migrate container registries from `etcd` to `postgreSQL`
Checklist: (if applicable)
- [ ] Milestone metadata specifying the target backport version
- [x] Mention to the original issue
- [x] Installer updates including:
- Fixtures for db schema changes
- New mandatory config options
- [ ] Update of end-to-end CLI integration tests in
ai.backend.test - [ ] API server-client counterparts (e.g., manager API -> client SDK)
- [x] Test case(s) to:
- Demonstrate the difference of before/after
- Demonstrate the flow of abstract/conceptual models with a concrete implementation
- [ ] Documentation
- Contents in the
docsdirectory - docstrings in public interfaces and type annotations
- Contents in the
Resolves https://github.com/lablup/backend.ai/issues/1907
Changes
- Migrate container registry schema and data from
etcdtoPostgreSQL - Update
ContainerRegistrygraphql API argument fromhostnametoid (UUID) -
hostnameis changed intoregistry_name - Add
is_globalcolumn to theContainerRegistrytable
Just a little suggestion about type hint in
is_known_registry(). How about accepting onlydict(orMapping) type asknown_registriesparameter? Please enlighten me how theknown_registrieslooks like in list type and dict type
dict example:
{'stable': {'cr.backend.ai': URL('https://cr.backend.ai')}, 'community': {'cr.backend.ai': URL('https://cr.backend.ai')}, 'multiarch': {'cr.backend.ai': URL('https://cr.backend.ai')}}
list example:
['cr.backend.ai']
Note: list is not aware of project unlike dict type here as you see above example.
I am postponing milestone to 24.09. We managed to meet our internal deadline for per-user image customization feature (#1973). From now on, at this PR, let's focus on forming concrete definitions and stabilizing things rather than rushing for the merge approval.
This stack of pull requests is managed by Graphite. Learn more about stacking.
Join @jopemachine and the rest of your teammates on
Graphite
Backport to 24.03 is failed. Please backport manually.