Conductor waits for registration agent.
Instead of stopping, the conductor wait for a valid registration agent. Change-Id: I356769f3af21ed183fd1d99c82d0cccc4dfaccb3
This commit is contained in:
parent
d407504102
commit
e0ddecdeed
|
@ -80,6 +80,11 @@ class ConductorManager(object):
|
|||
|
||||
ragent = self.dbapi.get_registration_wampagent()
|
||||
|
||||
while not ragent:
|
||||
LOG.warn("Cannot find a registration agent. Waiting for it...")
|
||||
time.sleep(5)
|
||||
ragent = self.dbapi.get_registration_wampagent()
|
||||
|
||||
LOG.info("Found registration agent: %s on %s",
|
||||
ragent.hostname, ragent.wsurl)
|
||||
|
||||
|
|
|
@ -585,7 +585,7 @@ class Connection(api.Connection):
|
|||
.filter_by(ragent=True, online=True)
|
||||
.one())
|
||||
except NoResultFound:
|
||||
raise exception.WampRegistrationAgentNotFound()
|
||||
return None
|
||||
|
||||
def unregister_wampagent(self, hostname):
|
||||
session = get_session()
|
||||
|
|
Loading…
Reference in New Issue