Skip to content

[Bug]: Database finalizer removal slow when deleting namespace due to exponential backoff #9554

@mnencia

Description

@mnencia

Is there an existing issue already for this bug?

  • I have searched for an existing issue, and could not find anything. I believe this is a new bug.

I have read the troubleshooting guide

  • I have read the troubleshooting guide and I think this is a new bug.

I am running a supported version of CloudNativePG

  • I have read the troubleshooting guide and I think this is a new bug.

Contact Details

No response

Version

trunk (main)

What version of Kubernetes are you using?

1.34

What is your Kubernetes environment?

Self-managed: kind (evaluation)

How did you install the operator?

YAML manifest

What happened?

The E2E test Declarative database management / will not prevent the deletion of the namespace with lagging finalizers fails intermittently with a timeout.

The reason is that when a cluster has DeletionTimestamp != nil, the controller still attempts regular reconciliation instead of immediately entering the deletion path. This reconciliation causes failures when trying to create resources in a terminating namespace, resulting in an exponential backoff that delays finalizer removal beyond the test timeout.

The problem self-corrects eventually, but is visible to the user as an excessively slow namespace deletion.

Ideal continuation fo the work done in #9430

Cluster resource

N/A

Relevant log output

See https://github.com/cloudnative-pg/cloudnative-pg/actions/runs/20419155679

Code of Conduct

  • I agree to follow this project's Code of Conduct

Metadata

Metadata

Assignees

Labels

E2E testsE2E tests tickets for easy triage on release processbug 🐛Something isn't working

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions