added in the ha cluster reactive and def in trove library.

This commit is contained in:
Jonathan Arrance 2016-09-13 23:26:25 -04:00
parent 07ab943394
commit 5f65401663
2 changed files with 8 additions and 1 deletions

View File

@ -60,6 +60,11 @@ def db_sync():
"""
TroveCharm.singleton.db_sync()
def configure_ha_resources(hacluster):
"""Use the singleton from the TroveCharm to run configure_ha_resources
"""
TroveCharm.singleton.configure_ha_resources(hacluster)
def setup_endpoint(keystone):
"""When the keystone interface connects, register this unit in the keystone
catalogue.

View File

@ -55,7 +55,9 @@ def setup_database(database):
trove.assess_status()
#this is to check if ha is running
#@reactive.when('ha.connected')
@reactive.when('ha.connected')
def cluster_connected(hacluster):
trove.configure_ha_resources(hacluster)
@reactive.when('identity-service.connected')
def setup_endpoint(keystone):