Skip to content

Table manager ignores prefixes for retention deletes #1340

@nrjpoddar

Description

@nrjpoddar

If retention is enabled on table-manager -table-manager.retention-deletes-enabled & -table-manager.retention-period=<>, table manager tries to delete all tables in DynamoDB if the retention criterion is met irrespective of the prefixes (set by -dynamodb.chunk-table.prefix=cortex_chunks_ & -dynamodb.periodic-table.prefix=cortex_weekly_).

Issue is the logic here will always create a v1 schema config (if you're using legacy schema based on CLI args) whose ChunkTables PeriodConfig prefix is never set.

Then the table manager code tries to prefix match for an empty string which always matches and all DynamoDB tables get added to the toDelete list.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions