Browse Source

Fix some API calls for PostgreSQL

Change-Id: Ia42c72dd3ce88b083b55fa73936b81c78da21166
tags/14.0.0.0rc1
Lingxian Kong 2 weeks ago
parent
commit
df4f74769e
5 changed files with 8 additions and 8 deletions
  1. +3
    -0
      trove/guestagent/datastore/manager.py
  2. +0
    -3
      trove/guestagent/datastore/mysql_common/manager.py
  3. +1
    -1
      trove/guestagent/datastore/mysql_common/service.py
  4. +1
    -1
      trove/guestagent/datastore/postgres/service.py
  5. +3
    -3
      trove/templates/postgresql/validation-rules.json

+ 3
- 0
trove/guestagent/datastore/manager.py View File

@@ -316,6 +316,9 @@ class Manager(periodic_task.PeriodicTasks):
LOG.info('No post_prepare work has been defined.')
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):
self.app.stop_db()



+ 0
- 3
trove/guestagent/datastore/mysql_common/manager.py View File

@@ -106,9 +106,6 @@ class MySqlManager(manager.Manager):
# This instance is a replication slave
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):
"""Create backup for the database.



+ 1
- 1
trove/guestagent/datastore/mysql_common/service.py View File

@@ -654,7 +654,7 @@ class BaseMySqlApp(service.BaseDbApp):

if not self.status.wait_for_status(
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")



+ 1
- 1
trove/guestagent/datastore/postgres/service.py View File

@@ -231,7 +231,7 @@ class PgSqlApp(service.BaseDbApp):

if not self.status.wait_for_status(
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")



+ 3
- 3
trove/templates/postgresql/validation-rules.json View File

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


Loading…
Cancel
Save