AgentListener initialization was fixed

When Murano Agent is disabled AgentListener was not
initialized properly which caused deployment errors.

This is partial backport of the
https://review.openstack.org/#/c/387993/. That commit
was supposed to fix tests that do not exist in Murano Newton
and thus wasn't backported.

Change-Id: I1a9f61c6b0020c6d3a5812f4d8ed519dc3cb7b44
Closes-Bug: #1669903
Related-bug: #1634483
This commit is contained in:
Stan Lagun 2017-03-03 13:11:17 -08:00
parent eff579e844
commit b4d301da49
1 changed files with 1 additions and 4 deletions

View File

@ -33,10 +33,7 @@ class AgentListenerException(Exception):
@dsl.name('io.murano.system.AgentListener')
class AgentListener(object):
def __init__(self, name):
self._enabled = False
if CONF.engine.disable_murano_agent:
return
self._enabled = True
self._enabled = not CONF.engine.disable_murano_agent
self._results_queue = str('-execution-results-%s' % name.lower())
self._subscriptions = {}
self._receive_thread = None