Skip to content

[Feature Request] Volume names are a global namespace with no per-tenant scoping #1681

Description

@dushulin

Problem

Volume names form a single global namespace shared across all API keys, and a volume's name is used verbatim as its stable ID. This surfaces in two ways:

  1. Name collision across callers. handleCreateVolume sets volumeID = req.Name when a name is supplied, and VolumeRecord.Name carries a uniqueIndex. Two independent callers that pick the same volume name cannot coexist — the second POST /volumes fails with 409 volume already exists. Common names (data, cache, workspace) collide immediately.

  2. No ownership boundary. GET /volumes returns every volume regardless of the authenticated caller, and Sandbox.create(volume_mounts=…) resolves a volume purely by name with no ownership check, so any authenticated caller can enumerate and mount any other caller's volume.

A UUID is only generated when the caller omits the name entirely; the official SDK's Volume.create(name) makes name mandatory, so in practice every SDK-created volume is keyed by the human-supplied name.

Question

Is per-tenant (per-API-key) volume scoping on the roadmap? Concretely: is the intended model that volume names be unique per owner rather than globally, with an internal opaque ID as the stable key — so that different callers may reuse the same human-readable name, and list/attach are scoped to the owner?

Environment

Observed on master (CubeMaster/pkg/service/httpservice/cube/volume.go, CubeMaster/pkg/base/db/models/volume.go, CubeAPI/src/handlers/volumes.rs).

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

area/CubeMasterImpacts the CubeMatser (control plane)enhancementNew feature or request

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions