Skip to content

Add optional label property to storage buckets #1354

@bogdanfazakas

Description

@bogdanfazakas

Storage buckets are currently identified only by an auto-generated UUID (e.g. 550e8400-e29b-41d4-a716-446655440000), which is opaque. Users have no way to attach a human-readable label/name at creation time, forcing dashboards or clients to maintain their own label-to-ID mappings externally.

An optional label (or name) field should be accepted at bucket creation time, stored in the database, and returned in all bucket listing and lookup responses. The field must remain optional so existing integrations are not broken.

  1. Database schema (PersistentStorageFactory.ts): add label TEXT (nullable) column to the persistent_storage_buckets table; include a migration path for existing rows
  2. Types:
    • Add label?: string to BucketRow
    • Add label?: string to PersistentStorageBucketRecord
    • Add label?: string to CreateBucketResult
  3. Command (src/@types/commands.ts): add label?: string to PersistentStorageCreateBucketCommand
  4. Handler (src/components/core/handler/persistentStorage.ts): pass label through PersistentStorageCreateBucketHandler.handle() and validate()
  5. Backend implementations: update createNewBucket() in both PersistentStorageLocalFS.ts and PersistentStorageS3.ts to accept and store the optional label
  6. Read path: ensure dbUpsertBucket() and all bucket-listing queries return the label field

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions