commit 5fb5a05be128a2ec6a912394aacd14b44eb82998
Author: Alex Kavanagh <email address hidden>
Date: Tue May 16 20:21:43 2023 +0100
Wait for Group Replication to finish; 3100 before commit error
The bug is triggered, as a race, usually by the
prometheus-relation-joined hook, when it tries to create a user whilst
Group Replication is recovering during a rolling restart. This patch
alters the create_user() method so that it detects the failure condition
and then retries for up to a minute (6 times, every 10 seconds) for the
Group Replication to recover before giving up and returning False
(indicating the the user was not created). This will usually result in
the handler not completing during the hook, and then retrying on the
next hook.
Reviewed: https:/ /review. opendev. org/c/openstack /charm- mysql-innodb- cluster/ +/883300 /opendev. org/openstack/ charm-mysql- innodb- cluster/ commit/ 5fb5a05be128a2e c6a912394aacd14 b44eb82998
Committed: https:/
Submitter: "Zuul (22348)"
Branch: master
commit 5fb5a05be128a2e c6a912394aacd14 b44eb82998
Author: Alex Kavanagh <email address hidden>
Date: Tue May 16 20:21:43 2023 +0100
Wait for Group Replication to finish; 3100 before commit error
The bug is triggered, as a race, usually by the relation- joined hook, when it tries to create a user whilst
prometheus-
Group Replication is recovering during a rolling restart. This patch
alters the create_user() method so that it detects the failure condition
and then retries for up to a minute (6 times, every 10 seconds) for the
Group Replication to recover before giving up and returning False
(indicating the the user was not created). This will usually result in
the handler not completing during the hook, and then retrying on the
next hook.
Change-Id: I5df4fd5ecbdd2b 7bce525a9930dcf fbc5868cbb8
Closes-Bug: #2018385