c80b323895
after fm containerization, nfvi would raise openstack alarms to the fm in pods. while retrieve both platform and openstack alarms are still required. So here we add NFVFaultMgmtAPI to get alarms from fm in pods and gather all alarms in vim strategy steps. add param "fault_management_pod_disabled" with 'True' as the default value into config file to disable nfvi get alarms from containerized fm. it will be removed in future Depends-On: https://review.opendev.org/658972/ Depends-On: https://review.opendev.org/662896/ Story: 2004008 Task: 30930 Change-Id: I79e0010f556f99923df25f355e554f43283d26f2 Signed-off-by: SidneyAn <ran1.an@intel.com>
30 lines
807 B
Python
30 lines
807 B
Python
#
|
|
# Copyright (C) 2019 Intel Corporation
|
|
#
|
|
# SPDX-License-Identifier: Apache-2.0
|
|
#
|
|
from nfv_common import debug
|
|
from nfv_common import tasks
|
|
|
|
from nfv_vim.nfvi._nfvi_plugin import NFVIPlugin
|
|
|
|
DLOG = debug.debug_get_logger('nfv_vim.nfvi.nfvi_fault_mgmt_plugin')
|
|
|
|
|
|
class NFVIFaultMgmtPlugin(NFVIPlugin):
|
|
"""
|
|
NFVI Fault Management Plugin
|
|
"""
|
|
_version = '1.0.0'
|
|
_signature = '2808f351-92bb-482c-b873-66ab232254af'
|
|
_plugin_type = 'fault_mgmt_plugin'
|
|
|
|
def __init__(self, namespace, pool):
|
|
scheduler = tasks.TaskScheduler('fault_mgmt_plugin', pool)
|
|
super(NFVIFaultMgmtPlugin, self).__init__(
|
|
namespace,
|
|
NFVIFaultMgmtPlugin._version,
|
|
NFVIFaultMgmtPlugin._signature,
|
|
NFVIFaultMgmtPlugin._plugin_type,
|
|
scheduler)
|