Skip to content

feat: Add region CRUD to catalog SQL driver#761

Open
mashawes wants to merge 1 commit into
openstack-experimental:mainfrom
mashawes:region-crud
Open

feat: Add region CRUD to catalog SQL driver#761
mashawes wants to merge 1 commit into
openstack-experimental:mainfrom
mashawes:region-crud

Conversation

@mashawes
Copy link
Copy Markdown
Collaborator

@mashawes mashawes commented Jun 5, 2026

feat: add region CRUD to catalog-driver-sql (#723)

Extends the catalog-sql driver with region CRUD, following the existing SQL-driver patterns.

  • Adds Region / RegionCreate / RegionUpdate / RegionListParameters types in core-types
  • Adds a region module to catalog-driver-sql (list/get/create/update/delete) with entity/domain conversions
  • Wires the operations into the CatalogBackend trait and SqlBackend impl
  • Adds a RegionNotFound error variant
  • Unit tests for each operation using MockDatabase

Reads mirror the existing service/endpoint modules. Create/update/delete follow the patterns used in other SQL drivers.

Closes #723

Note: this contribution was developed with AI assistance

@mashawes mashawes closed this Jun 5, 2026
@mashawes mashawes reopened this Jun 5, 2026
Copy link
Copy Markdown
Collaborator

@gtema gtema left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

mostly good, but few refinements are still necessary

Comment thread crates/core-types/src/catalog/region.rs
Comment thread crates/core-types/src/catalog/region.rs Outdated
Comment thread crates/core/src/catalog/backend.rs
Signed-off-by: Mohammed <mashawes@andrew.cmu.edu>
@mashawes
Copy link
Copy Markdown
Collaborator Author

mashawes commented Jun 5, 2026

Thanks for the review! Addressed all three points. Sorted struct fields and trait/impl methods alphabetically with blank lines between fields, and added validator length limits with max 255 characters taken from the Python region model. Ready for another look.

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.

Extend catalog-sql driver with region CRUD commands

2 participants