postgres-operator/pkg
Christian Rohmann 743aade45f
Use finalizers to avoid losing delete events and to ensure full resource cleanup (#941)
* Add Finalizer functions to Cluster; add/remove finalizer on Create/Delete events
* Check if clusters have a deletion timestamp and we missed that event. Run Delete() and remove finalizer when done.
* Fix nil handling when using Service from map; Remove Service, Endpoint entries from their maps - just like with Secrets
* Add handling of ResourceNotFound to all delete functions (Service, Endpoint, LogicalBackup CronJob, PDB and Secret) - this is not a real error when deleting things
* Emit events when there are issues deleting resources to the user is informed
* Depend the removal of the Finalizer on all resources being deleted successfully first. Otherwise the next sync run should let us try again
* Add config option to enable finalizers
* Removed dangling whitespace at EOL
* config.EnableFinalizers is a bool pointer

---------

Co-authored-by: Felix Kunde <felix-kunde@gmx.de>
2024-01-04 16:22:53 +01:00
..
apis Use finalizers to avoid losing delete events and to ensure full resource cleanup (#941) 2024-01-04 16:22:53 +01:00
apiserver Add operator deployment readiness probe (#1874) 2023-01-05 18:29:47 +01:00
cluster Use finalizers to avoid losing delete events and to ensure full resource cleanup (#941) 2024-01-04 16:22:53 +01:00
controller Use finalizers to avoid losing delete events and to ensure full resource cleanup (#941) 2024-01-04 16:22:53 +01:00
generated Bump v1.10.0 (#2299) 2023-04-20 18:21:43 +02:00
spec copy rolconfig during password rotation (#2183) 2023-01-25 10:48:23 +01:00
teams improve additional teams lookup (#2445) 2023-10-16 16:48:19 +02:00
util Use finalizers to avoid losing delete events and to ensure full resource cleanup (#941) 2024-01-04 16:22:53 +01:00