Skip to content

Replicator fails to delete orphaned copies on pod restart #357

@kavishdahekar

Description

@kavishdahekar

Describe the bug
If the replicator pods are restarted when its still in the middle of deleting copies of a source secret that was deleted, the new pod does not carry over the operation and the remaining copies are left orphaned and are not deleted.

To Reproduce

  1. create 100 destination namespaces with names destination-X where 1<=X<=100
  2. create source secret with replicator.v1.mittwald.de/replicate-to=destination-.* annotation
  3. wait for replicator to create copies of source secret in all 100 destination namespaces
  4. delete the source secret. replicator will now begin deleting all the 100 copies in the destination namespaces
  5. kill the replicator pods and wait for new pods to come up
  6. new replicator pods do not cleanup the remaining copies in the destination namespaces

Expected behavior
Replicator pods should finish the deletion task and not leave orphaned copies around.

Environment:

  • Kubernetes version: v1.30.5
  • kubernetes-replicator version: v2.10.2

Additional context
n/a

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions