176 Commits

Author SHA1 Message Date
Lingxian Kong
f79bb53a39 Support getting backups of a specific project
Change-Id: I6a6778ddbb1ee92da28a709be91b04873fe749fe
2020-09-13 23:55:11 +12:00
Lingxian Kong
8daade000c Support to check if subnet is associated with router
Change-Id: I8041fbfdb01a7a1efa721c623ab3f43efd2cc0f0
2020-08-24 13:17:49 +12:00
Lingxian Kong
4de40cb514 Support to update instance access
Change-Id: I640cd8b50fd0e0f80a1a45399b8bfdac437ae2b9
2020-08-11 09:35:14 +12:00
Lingxian Kong
cf3e9a6e74 Support to rebuild instance by admin
Change-Id: I48f8c6f997daeb6d82ff62b3325277d86fee2147
2020-08-06 20:38:11 +12:00
Lingxian Kong
8e48d757e6 Resize replicas (volume) together with primary
When resizing volume for an instance which is the primary of a
replication, cluster, Trove also resizes the volume for all the replicas
automatically.

Change-Id: I2e719772fe7abc719255ea2a705d9ec342aced2a
2020-07-28 09:13:05 +12:00
Lingxian Kong
ba046b2a14 Support online volume resize
Trove now supports to resize volume without downtime. To use this
feature, the version of Nova and Cinder needs to be at least Pike, the
config option ``cinder_service_type`` needs to be set to ``volumev3``.
The cloud admin can disable this feature by setting
``online_volume_resize=False``, default is enabled.

Change-Id: I000a4e90800454972dd39f2f82d286571bc0b96c
2020-07-24 13:55:51 +12:00
Lingxian Kong
828e873846 Support backup strategy API
Change-Id: I0ddd7214dae6e29ddfaf045fdb282f4980a8afff
2020-07-17 11:35:53 +12:00
Lingxian Kong
4bf6c496bb Release note for adding replicas in list instance response
Change-Id: Ib4e14d600841b6e6769a1e557b34c9c7787cb02d
2020-06-11 10:00:00 +12:00
Lingxian Kong
5354172407 Support subnet and IP for instance creation
Support ``subnet_id`` and ``ip_address`` for creating instance. When
creating instance, trove will check the network conflicts between user's
network and the management network, additionally, the cloud admin is
able to define other reserved networks by configuring
``reserved_network_cidrs``.

Change-Id: Icc4eece2f265cb5a5c48c4f1024a9189d11b4687
2020-06-10 22:41:35 +12:00
melissaml
b77f7b9fe7 Switch to newer openstackdocstheme and reno versions
Switch to openstackdocstheme 2.2.1 and reno 3.1.0 versions. Using
these versions will allow especially:
* Linking from HTML to PDF document
* Allow parallel building of documents
* Fix some rendering problems

Update Sphinx version as well.

Change pygments_style to 'native' since old theme version always
used 'native' and the theme now respects the setting and using 'sphinx'
can lead to some strange rendering.

Remove docs requirements from lower-constraints, they are not
needed during install or test but only for docs building.

openstackdocstheme renames some variables, so follow the
renames before the next release removes them. A couple of variables
are also not needed anymore, remove them.

See also
http://lists.openstack.org/pipermail/openstack-discuss/2020-May/014971.html

Change-Id: Ic5ff4981e5ed09885fd2aaad7508d58d2b2cccc7
2020-06-05 07:39:41 +00:00
Zuul
3202b321b3 Merge "Set status to ERROR if heartbeat expires" 2020-06-04 02:57:23 +00:00
Lingxian Kong
dc117d8dd8 Set status to ERROR if heartbeat expires
Change-Id: Ib8f5062094c0ec7766d4c6c6e7c3c8168e15ebd6
2020-06-04 10:12:04 +12:00
Lingxian Kong
a7af0e4df9 Support to remove datastore config parameters
CLI:
trove-manage db_remove_datastore_config_parameters mysql 5.7.29

Change-Id: Ia8b5828dfabd595d0ac33a2fdf1d9959f2d1d9ba
2020-05-29 23:46:44 +12:00
Lingxian Kong
e2b26fdd7d Trove doc and CI
Change-Id: I49bd6c824b837d22d9f3945a3e8c2343c831b352
2020-05-28 22:53:17 +12:00
Zuul
7079ca4033 Merge "Update master for stable/ussuri" 2020-04-26 03:53:16 +00:00
Lingxian Kong
429c39890e Support ip address type for instances
Include address type in getting instance response.

* Deprecate confip option network_label_regex as we don't reply on Nova
  to get addresses, network names don't make any sense.
* Add 'addresses' in instance API response, keep 'ip' as is but mark
  it deprecated in API doc, python-troveclient shouldn't break.

Story: 2007562
Task: 39445

Change-Id: Ia0458b5ddae8959ce29c17e444e1a51a026283cd
2020-04-26 09:56:50 +12:00
db76fe96fd Update master for stable/ussuri
Add file to the reno documentation build to show release notes for
stable/ussuri.

Use pbr instruction to increment the minor version number
automatically so that master versions are higher than the versions on
stable/ussuri.

Change-Id: Ia8b6938a031718fcfd72b25dfd1f506fa06012e6
Sem-Ver: feature
2020-04-24 08:49:00 +00:00
Lingxian Kong
a4057b10af Added checks for deleting datastore version
* Hard delete the datastore_configuration_parameters table record.
* Make 'datastore_version_id' nullable for 'instances' table.
* Check if the datastore version is still being used before removal.

Story: 2007563
Task: 39451
Change-Id: I84e4a31f14f9327cc01ff2d699167d91112e1565
2020-04-23 10:18:03 +12:00
Lingxian Kong
bcda317fd2 Release note for XFS disk format support
Change-Id: I8f89ce57c7c36520cee7ad1714f8405bbd03e649
2020-03-26 08:34:41 +13:00
Lingxian Kong
dfe826402b Config admin clients as default
Change-Id: Ib4dc349ab7ed4193189ed6bc2bae699d51064998
2020-01-19 16:11:41 +13:00
Lingxian Kong
4551a6cd7c Delete datastore
Admin user can delete datastore if there are no instances or backups
associated.

Change-Id: If15b79661859d5c40f4d9e5fe65e478954b6ddd4
2020-01-11 22:54:09 +13:00
Lingxian Kong
75b9b686b1 Show service_status_updated in instance API
A new field named ``service_status_updated`` is added to the instance
API response which e.g. could be used to validate if the instance
'HEALTHY' status is stale or not.

Change-Id: Iabcfad81343a71304b843b3a7778486253220d20
2019-12-18 22:13:46 +00:00
Lingxian Kong
a0a10f0b94 Support HEALTHY status for db instance
- 'HEALTHY' means the db service is responsive, 'ACTIVE' means the db
  service is alive.
- Remove the CI job fakemodetests, but will add similar testing task in
  the future.
- Fix the periodic CI job
- Remove MongoDB and  related jobs

Change-Id: I5abe9091ba203297dc87db5fba139179166321f7
2019-12-14 12:55:56 +13:00
Ghanshyam Mann
e6f55c57d5 [ussuri][goal] Drop python 2.7 support and testing
OpenStack is dropping the py2.7 support in ussuri cycle.

Trove is ready with python 3 and ok to drop the
python 2.7 support.

Complete discussion & schedule can be found in
- http://lists.openstack.org/pipermail/openstack-discuss/2019-October/010142.html
- https://etherpad.openstack.org/p/drop-python2-support

Ussuri Communtiy-wide goal:
https://governance.openstack.org/tc/goals/selected/ussuri/drop-py27.html

Change-Id: I6b448747c873bfc9c0138c0f7e3ca67ddce02dee
2019-12-05 22:38:19 +13:00
Lingxian Kong
e5637f00e2 Release note for service_credentials config
Change-Id: I179005a5bcf2a2c01ecae068a400503b412cd9e2
2019-10-11 14:13:14 +13:00
Zuul
f729b9e05d Merge "Add release note for public images" 2019-09-25 20:32:13 +00:00
ad19d37b92 Update master for stable/train
Add file to the reno documentation build to show release notes for
stable/train.

Use pbr instruction to increment the minor version number
automatically so that master versions are higher than the versions on
stable/train.

Change-Id: I36e88fb908532569b2e39a3e0c4de5ef7c503250
Sem-Ver: feature
2019-09-25 08:41:57 +00:00
Lingxian Kong
8f4bad30a0 Add release note for public images
Change-Id: I15325cb750b521471dae326572b65cd33e2c6ef3
2019-09-25 20:37:25 +12:00
Lingxian Kong
19d192e55f Release note for public instance
Story: 2006500
Task: 36467
Change-Id: I1eb95f94ca1d242e4539b4a0cf5906ee62f74284
2019-09-11 20:45:33 +12:00
Lingxian Kong
a1aa15282e Support management security group
Allow the cloud admin to control the security groups on the management
port of Trove instance, a new config option `management_security_groups`
is introduced for that purpose.

Change-Id: I4b22b87d37792be700d4ec7f78a7ea479ddb5814
Story: 2006466
Task: 36395
2019-09-02 10:06:49 +12:00
Lingxian Kong
858be70657 Release note for backup filtering
Change-Id: Ie7a8b4ccc90dc83fa7ced1b3c6361b9ff81f8d83
Story: #2006433
Task: #36345
2019-08-26 15:52:31 +12:00
Sam Morrison
62a2385790 Add a designate V2 API dns driver
Change-Id: Iafb36333a37146787c57eded139b4c2e071d69b0
2019-08-14 22:09:27 +00:00
Lingxian Kong
35301fa898 Fix the structure in releasenotes folder
Change-Id: I4a232fb3148faec690d1bc2096001c5eb6108954
2019-06-06 16:09:51 +12:00
Przemysław Godek
4823dd2f55 Add releasenotes for Redis upgrade
Change-Id: I3a878b7cc1f1e50d8860a5e9bcbc9469d101b232
Signed-off-by: Kasper Hasior <k.hasior@samsung.com>
2019-05-23 09:57:33 +02:00
Bartosz Zurkowski
59e8cb7e75 Extend cluster events
This patch extends adds a new field 'instance_ids' in payloads of two
cluster events:
     - DBaaSClusterShrink (during start and end notification),
     - DBaaSClusterGrow (during end notification).

Moreover, additional end notifications after growing and shrinking
cluster have been added.

The purpose of this change if to enable better integration with
tools for monitoring resources usage.

Change-Id: I2c39b2c3bff65f88e46944eda22209bdc92803bc
Signed-off-by: Kasper Hasior <k.hasior@samsung.com>
Co-Authored-By: Kasper Hasior <k.hasior@samsung.com>
Story: #2005520
Task: #30639
2019-05-12 02:06:42 +00:00
Lingxian Kong
a3de34dbc7 Nova keypair support
Now Trove doesn't support to specify keypair when creating the db
instance, the ssh key is injected into the guest agent image at the
build time, which makes it very hard to manage.

This patch adds a config option `nova_keypair` that is used as keypair
name when creating db instance. The old way of the image building will
be changed in the subsequent patches.

Change-Id: I41d4e41fc4bc413cdd48b8d761429b0204481932
Story: #2005429
Task: #30462
2019-04-17 20:04:58 +12:00
Zuul
f4e17a34b9 Merge "Update master for stable/stein" 2019-04-11 00:12:43 +00:00
Lingxian Kong
44fbcfaaa6 Deprecate the config option default_neutron_networks
Use `management_networks` instead. `management_networks`will be used
as admin networks which will be attached to Trove instance
automatically.

Change-Id: I5c6004b568c3a428bc0f0a8b0e36665d3c5b3087
2019-03-26 14:14:31 +13:00
2884110f3d Update master for stable/stein
Add file to the reno documentation build to show release notes for
stable/stein.

Use pbr instruction to increment the minor version number
automatically so that master versions are higher than the versions on
stable/stein.

Change-Id: I9b2d3f826e618579428a10dd4a6eb7aae88259ee
Sem-Ver: feature
2019-03-22 16:26:26 +00:00
weiyj
3d5f3dccea update spelling error
Change-Id: I4d260b00220c999072e193f5289fa1212074dcf9
2018-12-31 15:04:33 +08:00
Zuul
9d1bb44bc9 Merge "Add detailed list for instances" 2018-10-25 03:34:28 +00:00
whoami-rajat
ace53c47fa Add trove-status upgrade check command framework
This adds basic framework for trove-status upgrade
check commands. For now it has only "check_placeholder"
check implemented.
Real checks can be added to this tool in the future.

Change-Id: Idfeab4c06cba6f841c17ab6e255a29e8707bfa55
Story: 2003657
Task: 26162
2018-10-22 12:56:28 +05:30
Bartosz Zurkowski
f9fd69e9c6 Add detailed list for instances
Currently, listing instances only allows to get basic information about
entities. To get the details, one need to query instance "show" endpoint
for each instance separately. This is inefficient and exposes API to a
heavier load.

There are use cases in which we want to obtain detailed information
about all instances. In particular, in services integrating with Trove.
For example, Vitrage project requires this information to build vertices
and edges in the resource graph for RCA analysis.

Change-Id: I33252cce41c27cc7302c860dde1f6448ecdf3991
Signed-off-by: Bartosz Zurkowski <b.zurkowski@samsung.com>
2018-10-08 13:51:54 +02:00
Gaetan Trellu
dff637ad27 endpoint_type option not used with single tenant
Currently we are not able to specify the endpoint_type
for Neutron, Nova and Cinder clients with single tenant.

publicURL is configured by default but it could be nice
to have the possibility to choose anything else.

Change-Id: Ibb791cacc0e08de2d87b4348f84c9e573849ec51
Closes-Bug: #1776229
2018-09-27 08:18:57 +00:00
c50ab54d34 Update reno for stable/rocky
Change-Id: I03f5565b9895deac1a66e2789e163c510a9b936a
2018-08-09 10:27:49 +00:00
zhanggang
f06f65dcba Add extended properties support for mongo cluster.
Currently when create a mongodb cluster, mongos and configsvr
use the volume_size of replica-set node. But mongos and configvr
are not data node, they don't need volume space as large as data
node. This patch attend to help user specify the number, the volume
size and the volume type of mongos/configserver with
extended_properties[1] argument when creating mongodb. Currently,
the supported parameters are, num_configsvr, num_mongos,
configsvr_volume_size, configsvr_volume_type, mongos_volume_size
and mongos_volume_type.

[1] https://review.openstack.org/#/c/206931/

Closes-Bug: #1734907

Signed-off-by: zhanggang <zhanggang@cmss.chinamobile.com>
Change-Id: Ie48f3961b21f926f983c6713a76b0492952cf4c7
2018-08-07 17:42:36 +08:00
Zhao Chao
5895cf0ee9 Avoid diverged slave when migrating MariaDB master
When promoting one slave to the new master in a replication group,
previously the old master will be attached to the new one right after
the new master is on. For MariaDB, attaching the old master to the new
one, new GTID may be created on the old master and also may be synced
to some of the other replicas, as they're still connecting to the old
master. The new GTID does not exists in the new master, making these
slaves diverged from the master. After that, when the diverged slave
connects to the new master, 'START SLAVE' will fail with logs like:

    [ERROR] Error reading packet from server: Error: connecting slave
    requested to start from GTID X-XXXXXXXXXX-XX, which is not in the
    master's binlog. Since the master's binlog contains GTIDs with
    higher sequence numbers, it probably means that the slave has
    diverged due to executing extra erroneous transactions
    (server_errno=1236)

And these slaves will be left orphan and errored after
promote_to_replica_source finishs.

Attaching the other replicas to the new master before dealing with the
old master will fix this problem and the failure of the
trove-scenario-mariadb-multi Zuul job as well.

Closes-Bug: #1754539
Change-Id: Ib9c01b07c832f117f712fd613ae55c7de3561116
Signed-off-by: Zhao Chao <zhaochao1984@gmail.com>
2018-03-09 10:51:41 +08:00
Zhao Chao
d597bb4714 Return 204 instead of 200 for root-disable API
As no content will be returned to the client if a root-disable request
succeeds, a HTTP 204 (Not Content) response is more appropriate.

Redis root-disable scenario test fails because it's return HTTP 204, but
all API related tests are expecting a HTTP 200. Although changing Redis
root-disable API is a much simpler way to resolve the problem, migrating
from HTTP 200 to HTTP 204 should be a better solution. Related tests and
documents are also updated accordingly.

APIImpact

Change-Id: If732a578009fd35436e810fb7ceceefd1ada3778
Signed-off-by: Zhao Chao <zhaochao1984@gmail.com>
2018-03-02 20:57:23 +08:00
Zuul
f18779278c Merge "Remove support of creating volume from Nova." 2018-02-11 20:30:56 +00:00
Zhao Chao
29362a18a4 Remove support of creating volume from Nova.
Current Nova server volume support is broken. Nova also declared the
'os-volumes_boot' will be deprecated in the future. As creating volumes
by cinderclient has been supoorted for a long time, we could just drop
support of Nova server volume.

This patch also migrate to the new block_device_mapping_v2 parameter of
Nova servers creating API.

Closes-Bug: #1673408
Change-Id: I74d86241a5a0d0b1804b959313432168f68faf89
Signed-off-by: Zhao Chao <zhaochao1984@gmail.com>
2018-02-09 14:30:50 +08:00