Skip to content

[Feature] Delete entire group #13407

@hanahmily

Description

@hanahmily

Search before asking

  • I had searched in the issues and found no similar feature requirement.

Description

  • Objective: Implement end-to-end deletion for a whole group, including removing all physical data and purging metadata from the metadata repository.
  • Scope
    • Remove all physical data structures of the group:
      • Streams/measures data files, indexes, snapshots.
    • Remove the group metadata and all child metadata (streams/measures) from the metadata repo atomically.
    • Cluster-wide orchestration: block new writes for the group, drain/flush, then delete.
  • Requirements
    • Idempotent API/CLI: DELETE /groups/{group} (server-side implements best-effort idempotency).
    • Safety: optional dry-run, force=true for non-empty groups, preflight checks (no active schema changes).
    • Ordering:
      1. Quiesce group (reject new writes, wait for in-flight ops).
      2. Close the group tsdb.
      3. Remove physical data by the path prefix of the group.
      4. Purge metadata (group and descendants) from repo.
      5. Broadcast/evict routing, and discovery entries.
    • Observability: Using metadata to track the progress of the deletion.
  • Acceptance Criteria
    • Deleting a group removes all on-disk data and metadata and prevents new writes/reads.
    • Operation is idempotent and safe under retries and leader failover.
    • Works across rolling clusters; no orphaned files remain.
    • Docs include an admin guide and recovery caveats.

Use case

No response

Related issues

No response

Are you willing to submit a pull request to implement this on your own?

  • Yes I am willing to submit a pull request on my own!

Code of Conduct

Metadata

Metadata

Assignees

No one assigned

    Labels

    databaseBanyanDB - SkyWalking native databasefeatureNew feature

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions