During guestagent volume operations the calls to unmount check if the
volume is mounted first. The python function os.path.ismount returns
False if the directory if not readable by the current user, breaking
this functionality for some datastores.
The symptom of this failure is that the device ends up mounted twice
during prepare and then fails to unmount fully during resize.
The fix is to create a custom is_mount function that runs as the root user.
Change-Id: I151402717386230371bafcedc170d70b3588e912
Closes-Bug: #1645773
Setting up the connection to mysql doesn't work if the host
is a IPv6 address. Make sure we only use IPv4 addresses
at the moment.
Also removed pool_recycle and echo kwargs from EngineFacade
as they are no longer supported.
Change-Id: I6464c0031ba5b504ff103d8f62093d252deb87bb
When registering a new test group we
give it a group name and a list of tests to run.
register(['foo'], [t1, t2, t3])
creates group 'foo' running tests t1, t2 and t3.
This method has been extended to allow passing a dict
of tests with keys used as group name suffixes.
register(['foo'], sub1=[t1, t2], sub2=[t3])
creates group 'foo' running all tests t1, t2 and t3
and groups 'foo_sub1' running t1, t2
and group 'foo_sub2' running t3
The plan is to split long-running datastore tests
into multiple sub-groups that can run as separate jobs.
Generally, we will want to run replication and
clustering in one job separate from everything else.
I have registered a 'single' (tests on a single instance)
and 'multi' (tests woring on a set of instances) sub-groups
for all datastores (for consistency).
This does not change how the tests run.
It just creates '*_single' and '*_multi' sub-groups in addition
to the existing '<datastore>_supported' groups.
We will need to update the project config to run sub-jobs
for datastores that require it.
Change-Id: Iea2a996043b4c2d1889995e160891af33ffab5b6
The grow and shrink operations in Galera_common were eating exceptions.
This change passes the exceptions back and adds unit tests to
ensure such.
Change-Id: I3202d6d4daa77a8a185a427b31b2187eab4d82e9
Closes-bug: 1634627
Instead of assuming the user knows to specify a datastore for
kick-start and run-ci, we should throw an error and provide
guidance on what to do.
Change-Id: I5d4f73ff891df948f95f8dc2e3faae7c93a9f247
The log_generator_user_by_row tests fail sometimes as there may
be data written into the user log while the test is ongoing.
This changes the state from 'Published' to 'Partial' and the
test fails.
The test has been changed to also accept 'Partial' as a valid state.
Change-Id: Iab530fe503336c83e9b948c2c008d371a8030a1e
Closes-Bug: 1643015
There is a race condition in showing a cluster wherein the
server gets the list of instances from the db and then iterates
over the list to get the server information. If a shrink
operation is in progress, it can happen that one of the
instances is no longer present when trying to retrieve
the server info, and this causes the show command to throw
a NotFound error.
This is now trapped and the 'missing' server excluded from the list.
Change-Id: I54edc4acac09ca2278f525c08ad0d87576f0549e
Closee-Bug: 1643002
Our readmes and rst files had references to trove-integration and
redstack. This commit cleans up those references.
Jian Song had also been trying to make some of these kinds of changes
to the documentation and to reduce conflicts and merges, I'd requested
him to hold off. As a result, I think it is only fair that I list him
as a co-author.
Change-Id: I685659391fd04eefd250e72d789da5a0d7b7aace
Co-Authored-By: jiansong <jian.song@easystack.cn>
When you do a cluster-show, the instance list contains all ips.
The summary (which is the one displayed and used for tests)
only lists the first ip from each instance. It should list them
all, so the user could potentially chose which one they wanted
(i.e. an IPV4 address vs. an IPV6 one).
Depends-On: I54edc4acac09ca2278f525c08ad0d87576f0549e
Change-Id: I2ede074eb9bdf26420750f19f3aa4b8d057c5d7d
Closes-Bug: 1642695
The scenario tests currently use the first ip address (or in the
case of clusters, all) that is found. Unfortunately some datastores
don't support IPV6, so if a non-ipv4 ip is used, the test will fail.
Until all datastores support IPV6 (or we can come up with a strategy
to intelligently decide which to use) we should only use the IPV4 ips,
so the tests have been changed to accomodate this.
Closes-Bug: 1642741
Depends-On: Ia4fc545a10c7c16532aefd73818dd7d90c9c271b
Change-Id: I6aff776680c9c0632d8965c3ed70ed26db0a63f2
<long rant deleted>
This change enables the hacking extensions ability in trove. That
includes bumping the version of hacking that we use, and also adding
the enable-extensions like in the [flake8] section. I've enabled two
of the hacking extensions here.
There are some limitations to the hacking rules that I've enabled so
I'm also going to enter two bugs that others can fix (if they so
desire).
Change-Id: I6d8fc4bc03f948b84ad823e5248d78a4caa5c042
Related-Bug: 1642554
Related-Bug: 1642552
Some times when there's a server error, there is no
'fault' attribute on the server record. This caused
Trove to throw an exception. This has been fixed.
Change-Id: I47cbe9e899cb0767c377d184f123e38eda5b6a05
Depends-On: Ia4fc545a10c7c16532aefd73818dd7d90c9c271b
Closes-Bug: #1642636
Check that the database exists before deleting it and
fail if it does not.
Trove database API implementation closely followed MySQL
behavior which is to silently ignore deletes on non-existing
databases.
This strategy however no longer works that well with
other datastores which generally fail.
Trove users should be given a consistent experience.
Failing with an explanatory message is safer with respect to other
datastores and it is also consistent with how other Trove API
(user, backup, cluster) work.
Note: guestagent implementation was fix to handle
limit=None in database (and user) queries.
N >= None always returns True
Change-Id: I1dc26c7b40d6e4867b145b8470e6e5277e5dcdb4
Closes-Bug: 1293954
As per OpenStack licensing guide lines [1]:
[H104] Files with no code shouldn't contain any license header nor
comments, and must be left completely empty.
[1] http://docs.openstack.org/developer/hacking/#openstack-licensing
Change-Id: I0eb8829ad0406e8afb94ddc4fd4d4c7aab1c0270
This is an initial attempt at supporting multiple regions. It should
handle the mechanics of deploying an instance/volume to a remote
region. Additional changes may be required to allow the guest
agent on the instance to connect back to the originating region.
Co-Authored-By: Petr Malik <pmalik@tesora.com>
Change-Id: I780de59dae5f90955139ab8393cf7d59ff3a21f6
The command used to delete security groups is invalid. Changed
"nova security group delete" to "openstack security group delete"
Change-Id: If10577250e8db6fdcb89c959ca3a9e137c132cd3
Closes-bug: 1638884
With neutron, the default network is br-ex and the existing test fails
to handle that properly. This code works fine with both nova
networking and neutron.
Change-Id: Id0d25bf5abb0545a121a4a5e2191fb05d2005f04
Depends-On: I045a3744ef52819f379c0cc2ca4fc2bf552cad5d
Closes-Bug: #1619030
Add additional information with links to the Trove installation guides
found in the OpenStack documentation.
Co-Authored-By:jiansong <jian.song@easystack.cn>
Change-Id: Ic46b84a48faf77e1a609d2abf94fffb002e92112