Commit Graph

1831 Commits

Author SHA1 Message Date
Alex Kavanagh
21ff72926b Additions for the Octavia Upgrade tests
These are additions to make the Octavia Upgrade tests in the
charmed-openstack-tests repository a little easier to specify.  Also
depends on the zaza change [1].

[1] https://github.com/openstack-charmers/zaza/pull/442
2021-04-29 19:25:34 +01:00
David Ames
5d533fba6a Restart blocked mysql routers (#565)
LP Bug #1918953 [0] was resolved on the mysql-innodb-cluster side using coordinated delayed action. Since then we have seen a similar issue in CI [1] after the pause and resume test. Mysql-router hangs with:
2021-04-21 20:42:05 metadata_cache WARNING [7f3f968d5700] Instance '192.168.254.18:3306' [72b4ac2c-a2dd-11eb-82a5-fa163e5a4b7e] of replicaset 'default' is unreachable. Increasing metadata cache refresh frequency.

This cannot be fixed from the cluster side. I will be looking into solutions on the mysql-rotuer side. But in the meantime, to unblock the mysql-innodb-cluster gate this change restarts blocked MySQL routers.

[0] https://bugs.launchpad.net/charm-mysql-router/+bug/1918953
[1] https://openstack-ci-reports.ubuntu.com/artifacts/test_charm_pipeline_func_full/openstack/charm-mysql-innodb-cluster/786514/3/8479/consoleText.test_charm_func_full_11494.txt
2021-04-23 17:26:52 +01:00
Billy Olsen
a05263f111 Update nova tests (#563)
Add test for the new nova_cc charm action syncing AZs

The new action is meant to sync the availability zones from the
underlying Juju provider with the OpenStack availability zones.

It is useful within MAAS environments to map the MAAZ AZs to
OpenStack AZs.

Also fix output check logic for sync az test.
The validation logic for the sync az test checks the specific output of
the command text, but this is dependent on ordering. The code also
validates that the hypervisors are added to the appropriate host
aggregates, so this changes the test to verify the action was successful
and has some output.

Also use the availability-zone based on the configured settings.
In the attempt to sync the az test, the availability zone is assumed
to be the JUJU_AVAILABILITY_ZONE environment setting. In various
scenarios, this is not what is used for the availability zone of a
compute node.
This change mimics the logic that's contained within the nova-compute
charm to determine which availability zone should be used for the
compute node.

Signed-off-by: Billy Olsen <billy.olsen@gmail.com>
Co-authored-by: Ionut Balutoiu <ibalutoiu@cloudbasesolutions.com>
2021-04-22 13:13:40 +02:00
David Ames
25ee5dc924 Merge pull request #561 from coreycb/master
Get OpenStack codename from /etc/openstack-release
2021-04-20 15:54:54 -07:00
Corey Bryant
d70ff79b1e Change log to debug to create less noise 2021-04-20 13:05:18 -04:00
Corey Bryant
9a48757d5e Fix version fallback path when /etc/openstack-release doesn't exist 2021-04-20 12:32:07 -04:00
Corey Bryant
0b401de17f Get OpenStack codename from /etc/openstack-release
In newer versions of Ubuntu and the Cloud Archive (currently Hirsute,
Wallaby, and above), there is an openstack-release package that, if
installed, specifies the current OpenStack release in
/etc/openstack-release.

Also adds wallaby definitions to non-version definitions in
os_versions.py.

Fixes #560
2021-04-20 10:31:04 -04:00
Aurelien Lourot
ff7a30d940 Merge pull request #559 from thedac/mysql-partition-tests
MySQL Partition Test class
2021-04-19 18:09:35 +02:00
David Ames
49929ef018 Fix typo 2021-04-19 09:05:45 -07:00
David Ames
1c15672b61 MySQL Partition Test class
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
2021-04-19 08:58:11 -07:00
David Ames
668b3233fb Merge pull request #556 from gnuoy/ovn-central-deferred-restart-test
Add deferred restart test for ovn central
2021-04-13 10:02:27 -07:00
Liam Young
669b57574b Add deferred restart test for ovn central 2021-04-13 10:24:15 +00:00
Aurelien Lourot
4b461a7bb8 Merge pull request #554 from gnuoy/issue/553
Fix Neutron Gateway deferred restart test
2021-04-12 11:39:20 +02:00
Liam Young
d89a1651d2 Fix Neutron Gateway deferred restart test
Do not run the deferred hooks action for neutron gateway as it is
not needed and will end in an action error.

Tested locally here: https://paste.ubuntu.com/p/cSmgxmrTr4/

This closes issue #553
2021-04-12 09:28:31 +00:00
Aurelien Lourot
6e1ef38b06 Merge pull request #551 from gnuoy/fix-deferred-restart-race
Fix race exposed by rabbit charm.
2021-04-09 22:12:12 +02:00
Liam Young
8a04739912 Fix race exposed by rabbit charm.
If there are multiple charms of a given application then a hook
like leader-settings-changed can trigger a deferred hook. So a
race can occur where the deferred hooks of unit1 are cleared
then in the process of clearing unit2 a deferred hook is
triggerred in unit1. To fix this do not block on the wl status
message after the hook test completes.

Also, make sure that an action failure is fatal to surface any
issues.
2021-04-09 20:02:27 +00:00
Billy Olsen
c8a62b686f Merge pull request #549 from gnuoy/fix-ovn-dedicateed-chassis-deferred
Fix bug caused by disable-mlockall being unset
2021-04-09 12:21:58 -07:00
Liam Young
7d02173914 Fix bug caused by disable-mlockall being unseet 2021-04-09 17:10:09 +00:00
Liam Young
01544d22ed Deferred restart test fixes (#540)
* Add ovn-chassis test
* Yet another refactor to reduce the amount that implementations need to override.
* Add ovn dedicated chassis support
* Fix race with checking wlm
2021-04-09 10:48:52 +01:00
Aurelien Lourot
877deb223b Merge pull request #543 from wolsen/bug/542
Fix Ceph service action tests
2021-04-09 10:52:17 +02:00
Billy Olsen
a6cd0ea62a Fix Ceph service action tests
The ServiceTest.test_start_specific under the ceph osd tests stops all
services using ceph-osd.target. This will stop all the OSDs, but the
restarting of any single OSD will restart all the OSDs. This behavior
causes the charm test to fail.

Unfortunately, this wasn't caught in the initial review because the test
is skipped when there are fewer the 2 OSDs on a unit and the final test
run skipped the test due to this condition.

Fixes #542

Signed-off-by: Billy Olsen <billy.olsen@gmail.com>
2021-04-08 14:12:11 -07:00
David Ames
fec0ed1892 Merge pull request #536 from dasm/bugfix/1917332
Functional test for `force-quorum-using-partition-of` action on mysql-innodb-cluster charm.
2021-04-02 11:52:37 -07:00
Dariusz Smigiel
4df0cbee8c Moved block_until_idle immediately after force-quorum cmd 2021-04-02 11:40:07 -07:00
Dariusz Smigiel
0858f016cd Fixed TokenError 2021-04-02 11:29:44 -07:00
Dariusz Smigiel
9a5e334b44 Addressed review comments 2021-04-02 11:05:52 -07:00
Dariusz Smigiel
795272269f Fixed typo 2021-04-02 07:52:18 -07:00
Dariusz Smigiel
8b47c8a37f Change the way how I'm checking state 2021-04-02 07:40:00 -07:00
Dariusz Smigiel
51a53d4e86 Verify at the end that cluster is in operable state 2021-04-02 07:12:06 -07:00
Dariusz Smigiel
66fd299f16 Fixed typo 2021-04-01 21:30:13 -07:00
Dariusz Smigiel
e8157f0df8 Addressed flake8 violations 2021-04-01 20:44:23 -07:00
Dariusz Smigiel
a891ff28d5 Added 'i-really-mean-it' tick to force-quorum 2021-04-01 16:38:21 -07:00
Dariusz Smigiel
fe8b78b7c6 Functional testing for mysql-innodb-cluster
This is a change with functional test for mysql-innodb-cluster
implementing `force-quorum-using-partition-of` feature.
It is addressing bug:
https://bugs.launchpad.net/charm-mysql-innodb-cluster/+bug/1917332
2021-04-01 14:08:54 -07:00
David Ames
0936b18322 Merge pull request #508 from gnuoy/deferred-restart-tests
Add test for deferred restarts
2021-03-30 11:51:35 -07:00
mkalcok
50c781fb53 Remove repetitive code. (#534) 2021-03-30 07:44:46 +01:00
Liam Young
f78105a646 Allow status message to be overridden 2021-03-29 14:46:04 +00:00
Liam Young
0fdd876213 Update inline with recent charm changes 2021-03-29 10:41:46 +00:00
mkalcok
88fe0af9cb Functional tests for nova-compute 'cloud' actions (#470)
* Functional test for 'enable' and 'disable' actions on nova-compute

* lint fixes

* Put tests of new functionality into separate class

* Added tests for actions `remove-from-cloud` and `register-to-cloud`

* Set longer timeout for action verification

* Add logging to help with CI debugging

* Raise error if action fails

* Cleanup running VMs before test starts

* Add cleanup to tests that create VMs
2021-03-27 08:27:02 +00:00
Aurelien Lourot
76dddb7097 Merge pull request #533 from thedac/issue/528
Fix test_vault_reload race condition
2021-03-26 18:28:02 +01:00
David Ames
e5d2acc88c Fix test_vault_reload race condition
The test_vault_reload test was checking for running config without giving the
config-change time to complete. Simply adding an idle wait resolves the issue.

Closes Issue: #528
2021-03-26 16:58:08 +00:00
David Ames
0ace737254 Merge pull request #514 from ajkavanagh/object-retrier
Object retrier
2021-03-25 09:09:08 -07:00
Aurelien Lourot
3997c6bb3e Merge pull request #531 from ajkavanagh/pin-lxml-2-6-2
Pin lxml to 4.6.2
2021-03-25 16:27:47 +01:00
Alex Kavanagh
e9f11da5df Fix typo and rename class for better understanding
Fixes a typo (None -> not None) and renames the class from
ObjectRetrier -> ObjectRetrierWraps to make it clearer that the class
instantiation is to wrap and object with the retrier code rather than do
retries at that moment.
2021-03-25 14:47:42 +00:00
Alex Kavanagh
8af30a5275 Pin lxml to 4.6.2
See https://github.com/openstack-charmers/zaza-openstack-tests/issues/530

Issue:

    Python 3.5. is deprecated/EOL
    Py35 is used on Xenial
    Xenial is used as the test platform to run tests.
    lxml is used by zaza-openstack-tests for the SAML assertions (because they are XML)
    lxml > 4.6.2 releases are after py3.5 has been deprecated/EOL.
    Therefore, no wheels are now built for lxml for py35.
    Thus there is a binary dependency to build lxml for testing
2021-03-25 11:46:47 +00:00
Billy Olsen
eae35cce96 Merge pull request #505 from ionutbalutoiu/add-glance-ceph-radosgw-tests
Add test for Glance with Ceph RGW backend
2021-03-24 15:28:55 -07:00
Liam Young
77cb2d0bd8 Fix doc string and lint 2021-03-24 13:52:34 +00:00
Ionut Balutoiu
0315ca680e Add test for Glance with Ceph RGW backend
This test shall be used for Glance testing bundles with Ceph
deployed, and multi-backend enabled.

It validates that images can be stored using the Ceph RGW (via
the OpenStack Swift API).
2021-03-24 15:28:51 +02:00
Liam Young
085d5a1513 Add RabbitMQDeferredRestartTest + fixes 2021-03-23 15:57:21 +00:00
David Ames
2a6517f6fd Add restart on change test (#527)
Add the restart on change test for mysql-router.
2021-03-23 15:32:01 +00:00
Liam Young
1f47ef0bd7 Update package restart message afer ch change 2021-03-22 18:43:13 +00:00
Frode Nordahl
451a1892cf Merge pull request #529 from openstack-charmers/lourot/rm-old-hacluster-scaleback-tests
Remove obsolete HaclusterScalebackTest
2021-03-22 13:50:30 +01:00