Doctor datasource - severity is not mandatory
Change-Id: I9cb5082b85deb43d8b4c16f3e277a7ab32899f6c
This commit is contained in:
parent
1c1fbb4cc7
commit
47b97c7e7c
@ -57,7 +57,6 @@ class DoctorDriver(AlarmDriverBase):
|
||||
|
||||
details = alarm[EventProps.DETAILS]
|
||||
return DoctorDetails.STATUS in details and \
|
||||
DoctorDetails.SEVERITY in details and \
|
||||
DoctorDetails.HOSTNAME in details
|
||||
|
||||
def _status_changed(self, new_alarm, old_alarm):
|
||||
|
@ -48,6 +48,9 @@ class DoctorTransformer(AlarmTransformerBase):
|
||||
details = entity_event.get(EventProps.DETAILS, {})
|
||||
details[VProps.NAME] = entity_event[EventProps.TYPE]
|
||||
details[EventProps.TIME] = entity_event[EventProps.TIME]
|
||||
if DoctorDetails.SEVERITY not in details:
|
||||
LOG.debug('adding default severity - CRITICAL')
|
||||
details[DoctorDetails.SEVERITY] = 'critical'
|
||||
|
||||
return graph_utils.create_vertex(
|
||||
self._create_entity_key(entity_event),
|
||||
|
Loading…
Reference in New Issue
Block a user