test_800_remove_leader is getting a reference to the mysql lead
unit, removing the unit and then attempting to retrieve the ip.
This used to work but no longer does, perhaps due to changes
in the way zaza interfacts with libjuju. This change stores
the lead ip address before removing the unit.
Currently the new partition test_110 is breaking on master due to the
test landing before the charm PR which implemented the change [0] has
landed.
Move the partition test to its own class which can be added as a target
in the charm's tests.yaml. This will not affect master and can be
trivially updated in [0].
[0] https://review.opendev.org/c/openstack/charm-mysql-innodb-cluster/+/779427
In the MySQL test we destroy a unit and then attempt to remove it from
metadata. The metadata removal (remove_instance action) gets stuck when it is
started while the destroyed unit has not been entirely removed and is still
running MySQL.
Wait for all the units to have cluster incomplete workload status message
before attempting the remove_instance.
* Updates to concurrent series upgrade
Updates to make it run more in parallel and spend less time waiting on
the whole model when updating machines.
* Make the concurrent series upgrade tests work
This is a number of changes to get the concurrent (here called
'parallel' historically) series upgrade tests to work. A number of
changes were required which included limiting the number of concurrent
async co-routines (futures) that could be run as with large models it
hits the limits of the Py3 runtime.
* Fix the tests and change pause order in maybe_pause_things
Due to an additional model helper call, an additional model AsyncMock is
required. Also the pause order had changed, and this is restored to
ensure the original design is retained (for pause order).
Clean up some commented out code and sort out a few PEP8 errors.
* Update comment to reflect code (3 -> 4)
* Fix tests that fail on bionic but pass on focal
Essentially, asyncio.gather has different behaviour on bionic that
focal. Although this doesn't affect testing, it does affect the unit
tests. These changes are simply to normalise the behaviour of unit
tests on focal and bionic.
Copy function from MySQLInnoDBClusterTests to test mysqldump
as standard on mysql applications.
DocImpact
Closes-Bug: #0000000
Implements: MySQL dump test
By including pre and pos-application functions, charm
series upgrades can be handled in a more generic way,
even when they require running additional actions
before a unit is upgraded, or after the whole application
is upgraded.
Verify the seeded file is present with the expected content since it will
be used by *-relation-changed hook to determine if it can process requests
of related units.
Related-Bug: #1868326