Open phvalguima opened 1 year ago
@marceloneppel I am not sure how backup tests pass (CI and manual) if @phvalguima is right. Should we fix something here?
@phvalguima I have quickly deployed the latest PostgreSQL:
ubuntu@juju350:~$ juju deploy postgresql-k8s --trust --channel 14/edge
Deployed "postgresql-k8s" from charm-hub charm "postgresql-k8s", revision 351 in channel 14/edge on ubuntu@22.04/stable
And I do see both Services and Endpoint patroni-<app>-config
:
ubuntu@juju350:~$ kubectl get endpoints -n testisterraform | grep patroni
patroni-postgresql-k8s-config <none> 3m14s
patroni-postgresql-k8s-sync <none> 3m10s
patroni-postgresql-k8s <none> 3m11s
ubuntu@juju350:~$ kubectl get services -n testisterraform | grep patroni
patroni-postgresql-k8s-config ClusterIP None <none> <none> 3m22s
ubuntu@juju350:~$
We are most probably do not use patroni endpoint here, but safety first: on recover let's clean garbage.
The only open question to resolve this GH issue on my side: should we also remove patroni-<app>-sync
endpoint here?
Otherwise feel free to resolve this issue.
CC: @marceloneppel , @dragomirp .
Looking into restore code for kubernetes, I can see in these lines that we must delete
patroni-<charm-name>-config
endpoint to restore from backup.However, Patroni coming from latest 14.9, channel=14/edge, does not exist as an endpoint. It exists as a
Service
. That section should fail during restore process.