Closed matejkostros closed 1 year ago
Everything works as expected. Patroni (which is, by the way, what produces the logs you attached) updates the xlog_location
(pg_current_wal_lsn()
) value (if it has changed) every HA loop. This causes resourceVersion
change.
Does it mean, that these status changes have purpose which I am missing?
maybe. your question is "why should xlog_location
be changed?"?
Yes. Do you suggest, i should take this under patroni then?
The updated value is used for patronictl list
output and for GET /async?lag=<max-lag>
endpoint. But you of course can create an issue in Patroni repo, I am sure @CyberDem0n will be happy to explain you this in details:)
We noticed that our Postgres cluster in Kubernetes deployment is showing too many statuses when watching only for changes. Following is snippet of approximately 5 minutes:
When we were looking into logs for this pod we found out that these status updates are precisely correlated with INFO messages from the kubernetes-postgresql-0 pod. Specifically status updates during the first info message after LOG message:
When we list manifest with
kubectl get po/kubernetes-postgresql-0 -o yaml
we noticed that only these (manifest also attached: kubernetes-postgresql-0.yaml.txt ) two fields change when status refreshes:Our kubernetes-postgresql-0 pod is:
We are using postgres-operator, but that is not showing any logs or status updates which would correlate with this issue, that is why I decided to post here.