def __init__(self, **data): """ constructor of the object """ LogicalDevice.__init__(self, **data) refAttributeNames = getRefAttributeNames(Host) # initialize OS List self.osList = [] self.eventInpObjs_shutdown = set([]) for (name, value) in data.items(): if name in IHost.names() or \ name in IEventIfEventHost.names(): if name not in refAttributeNames: setattr(self, name, value) self.ikRevision = __version__ self.workflows[WfPdNagios.id] = nagios_wf = WfPdNagios() setattr(nagios_wf.workflowRelevantData, "ddd", 5) setattr(nagios_wf.workflowRelevantData, "state", "-") setattr(nagios_wf.workflowRelevantData, "object", self) setattr(nagios_wf.workflowRelevantData, "new_state", "2_start") nagios_wf.start() #health self._counter = {'r': 500} self._health = 1.0 self._weight = {'r': 1.0} self._weight_user = 0.5
def __init__(self, **data): """ constructor of the object """ Component.__init__(self, **data) # initialize OS List self.osList = [] self.eventInpObjs_shutdown = set([]) for (name, value) in data.items(): if name in IHost.names() or \ name in IEventIfEventHost.names(): setattr(self, name, value) self.ikRevision = __version__ self.workflows[WfPdNagios.id] = nagios_wf = WfPdNagios() setattr(nagios_wf.workflowRelevantData, "ddd", 5) setattr(nagios_wf.workflowRelevantData, "state", "-") setattr(nagios_wf.workflowRelevantData, "object", self) setattr(nagios_wf.workflowRelevantData, "new_state", "2_start") nagios_wf.start()