diff --git a/devstack/gate_hook.sh b/devstack/gate_hook.sh index 91b736e15..b7d2caa09 100644 --- a/devstack/gate_hook.sh +++ b/devstack/gate_hook.sh @@ -23,10 +23,10 @@ export KEEP_LOCALRC=1 if [ -z ${DEVSTACK_LOCAL_CONFIG+x} ]; then DEVSTACK_LOCAL_CONFIG="enable_plugin vitrage git://git.openstack.org/openstack/vitrage" fi -DEVSTACK_LOCAL_CONFIG+=$'\nenable_plugin ceilometer git://git.openstack.org/openstack/ceilometer' -DEVSTACK_LOCAL_CONFIG+=$'\nenable_plugin aodh git://git.openstack.org/openstack/aodh' -DEVSTACK_LOCAL_CONFIG+=$'\ndisable_service ceilometer-alarm-evaluator,ceilometer-alarm-notifier' -DEVSTACK_LOCAL_CONFIG+=$'\ndisable_service n-net' +#DEVSTACK_LOCAL_CONFIG+=$'\nenable_plugin ceilometer git://git.openstack.org/openstack/ceilometer' +#DEVSTACK_LOCAL_CONFIG+=$'\nenable_plugin aodh git://git.openstack.org/openstack/aodh' +#DEVSTACK_LOCAL_CONFIG+=$'\ndisable_service ceilometer-alarm-evaluator,ceilometer-alarm-notifier' +#DEVSTACK_LOCAL_CONFIG+=$'\ndisable_service n-net' export DEVSTACK_LOCAL_CONFIG diff --git a/vitrage/datasources/nagios/transformer.py b/vitrage/datasources/nagios/transformer.py index 0ac18f3b3..6c90a8659 100644 --- a/vitrage/datasources/nagios/transformer.py +++ b/vitrage/datasources/nagios/transformer.py @@ -24,7 +24,6 @@ from vitrage.datasources.nagios import NAGIOS_DATASOURCE from vitrage.datasources.nagios.properties import NagiosProperties from vitrage.datasources.nagios.properties import NagiosTestStatus from vitrage.datasources.nova.host import NOVA_HOST_DATASOURCE -from vitrage.datasources.static_physical import SWITCH from vitrage.datasources import transformer_base as tbase from vitrage.datasources.transformer_base import Neighbor import vitrage.graph.utils as graph_utils @@ -84,7 +83,7 @@ class NagiosTransformer(AlarmTransformerBase): tbase.TIMESTAMP_FORMAT) resource_type = entity_event[NagiosProperties.RESOURCE_TYPE] - if resource_type == NOVA_HOST_DATASOURCE or resource_type == SWITCH: + if resource_type: return [self._create_neighbor( vitrage_id, timestamp, @@ -98,7 +97,8 @@ class NagiosTransformer(AlarmTransformerBase): sample_timestamp, resource_type, resource_name): - transformer = self.transformers[resource_type] + # Any resource transformer will do (nova for example) + transformer = self.transformers[NOVA_HOST_DATASOURCE] if transformer: properties = { diff --git a/vitrage/datasources/static_physical/transformer.py b/vitrage/datasources/static_physical/transformer.py index 65627d7d7..fe6da834e 100644 --- a/vitrage/datasources/static_physical/transformer.py +++ b/vitrage/datasources/static_physical/transformer.py @@ -84,7 +84,8 @@ class StaticPhysicalTransformer(ResourceTransformerBase): entity_key = self._create_entity_key(entity_event) timestamp = entity_event[DSProps.SAMPLE_DATE] - for neighbor_details in entity_event[self.RELATIONSHIPS_SECTION]: + for neighbor_details in entity_event.get( + self.RELATIONSHIPS_SECTION, {}): # TODO(alexey): need to decide what to do if one of the entities # fails neighbor = self._create_neighbor(neighbor_details, entity_type, diff --git a/vitrage/datasources/zabbix/transformer.py b/vitrage/datasources/zabbix/transformer.py index e8fd5fcb4..456da7f3e 100644 --- a/vitrage/datasources/zabbix/transformer.py +++ b/vitrage/datasources/zabbix/transformer.py @@ -23,7 +23,6 @@ from vitrage.common.datetime_utils import format_unix_timestamp from vitrage.datasources.alarm_properties import AlarmProperties as AlarmProps from vitrage.datasources.alarm_transformer_base import AlarmTransformerBase from vitrage.datasources.nova.host import NOVA_HOST_DATASOURCE -from vitrage.datasources.static_physical import SWITCH from vitrage.datasources import transformer_base as tbase from vitrage.datasources.transformer_base import Neighbor from vitrage.datasources.zabbix.properties import ZabbixProperties as ZProps @@ -98,7 +97,7 @@ class ZabbixTransformer(AlarmTransformerBase): timestamp = entity_event[ZProps.TIMESTAMP] resource_type = entity_event[ZProps.RESOURCE_TYPE] - if resource_type == NOVA_HOST_DATASOURCE or resource_type == SWITCH: + if resource_type: return [self._create_neighbor( vitrage_id, timestamp, @@ -112,7 +111,8 @@ class ZabbixTransformer(AlarmTransformerBase): sample_timestamp, resource_type, resource_name): - transformer = self.transformers[resource_type] + # Any resource transformer will do (nova for example) + transformer = self.transformers[NOVA_HOST_DATASOURCE] if transformer: properties = {