commit 83bc7b36aeb038b7ce2d16ec023fa971bfc091f1
Author: Felipe Reyes <email address hidden>
Date: Mon Aug 28 20:58:47 2023 -0400
Delay prom_exporter user creation until password is available.
There are situations where the create_local_prometheus_exporter_user()
handler could be executed in a follower unit before the leader units
gets the chance to generate a password for the prom_exporter user and
store it in the leader databag, this has the consequence that the
prom_exporter user is created with the password 'None' (string
representation of the `None` value), this leads to the problem that the
mysql_exporter daemon can't connect to mysqld.
This patch checks that the password is available, if it isn't, then bail
out and let subsequent executions to re-evaluate this condition.
Reviewed: https:/ /review. opendev. org/c/openstack /charm- mysql-innodb- cluster/ +/892989 /opendev. org/openstack/ charm-mysql- innodb- cluster/ commit/ 83bc7b36aeb038b 7ce2d16ec023fa9 71bfc091f1
Committed: https:/
Submitter: "Zuul (22348)"
Branch: master
commit 83bc7b36aeb038b 7ce2d16ec023fa9 71bfc091f1
Author: Felipe Reyes <email address hidden>
Date: Mon Aug 28 20:58:47 2023 -0400
Delay prom_exporter user creation until password is available.
There are situations where the create_ local_prometheu s_exporter_ user()
handler could be executed in a follower unit before the leader units
gets the chance to generate a password for the prom_exporter user and
store it in the leader databag, this has the consequence that the
prom_exporter user is created with the password 'None' (string
representation of the `None` value), this leads to the problem that the
mysql_exporter daemon can't connect to mysqld.
This patch checks that the password is available, if it isn't, then bail
out and let subsequent executions to re-evaluate this condition.
Closes-Bug: #2033306 06b11c293f63e73 bd0ab18897f
Change-Id: I58fc489fd4cc4e