Fix some API calls for PostgreSQL

Change-Id: Ia42c72dd3ce88b083b55fa73936b81c78da21166
This commit is contained in:
Lingxian Kong 2020-09-12 17:06:23 +12:00
parent 5482c54645
commit df4f74769e
5 changed files with 8 additions and 8 deletions

View File

@ -316,6 +316,9 @@ class Manager(periodic_task.PeriodicTasks):
LOG.info('No post_prepare work has been defined.') LOG.info('No post_prepare work has been defined.')
pass pass
def start_db_with_conf_changes(self, context, config_contents, ds_version):
self.app.start_db_with_conf_changes(config_contents, ds_version)
def stop_db(self, context): def stop_db(self, context):
self.app.stop_db() self.app.stop_db()

View File

@ -106,9 +106,6 @@ class MySqlManager(manager.Manager):
# This instance is a replication slave # This instance is a replication slave
self.attach_replica(context, snapshot, snapshot['config']) self.attach_replica(context, snapshot, snapshot['config'])
def start_db_with_conf_changes(self, context, config_contents, ds_version):
self.app.start_db_with_conf_changes(config_contents, ds_version)
def create_backup(self, context, backup_info): def create_backup(self, context, backup_info):
"""Create backup for the database. """Create backup for the database.

View File

@ -654,7 +654,7 @@ class BaseMySqlApp(service.BaseDbApp):
if not self.status.wait_for_status( if not self.status.wait_for_status(
service_status.ServiceStatuses.HEALTHY, service_status.ServiceStatuses.HEALTHY,
CONF.state_change_wait_time, update_db=False CONF.state_change_wait_time, update_db=True
): ):
raise exception.TroveError("Failed to start mysql") raise exception.TroveError("Failed to start mysql")

View File

@ -231,7 +231,7 @@ class PgSqlApp(service.BaseDbApp):
if not self.status.wait_for_status( if not self.status.wait_for_status(
service_status.ServiceStatuses.HEALTHY, service_status.ServiceStatuses.HEALTHY,
CONF.state_change_wait_time, update_db=False CONF.state_change_wait_time, update_db=True
): ):
raise exception.TroveError("Failed to start database") raise exception.TroveError("Failed to start database")

View File

@ -224,7 +224,7 @@
{ {
"name": "checkpoint_timeout", "name": "checkpoint_timeout",
"restart_required": false, "restart_required": false,
"type": "string" "type": "integer"
}, },
{ {
"name": "checkpoint_completion_target", "name": "checkpoint_completion_target",
@ -238,14 +238,14 @@
}, },
{ {
"name": "wal_keep_segments", "name": "wal_keep_segments",
"restart_required": false, "restart_required": true,
"min": 0, "min": 0,
"type": "integer" "type": "integer"
}, },
{ {
"name": "wal_sender_timeout", "name": "wal_sender_timeout",
"restart_required": false, "restart_required": false,
"type": "string" "type": "integer"
}, },
{ {
"name": "synchronous_standby_names", "name": "synchronous_standby_names",