public class AlarmSink extends Object
AlarmSink
represents a "sink" where
Alarm
objects are added in order to be written to the
alarm table.
The AlarmSink
relieves the user of writing directly into
the alarm table.
An AlarmSink
can be created in two ways: stand alone
or through AlarmSinkCentral
.
AlarmSink
is created with a Maapi
object which is used when writing to the alarm list.AlarmSinkCentral
In this mode, writing is handled by a proxy before it is written to
the alarm list. The AlarmSink
is created with its
default constructor and submitting is always done indirectly through
the AlarmSinkCentral
which is always started in an
NCS JVM.Constructor and Description |
---|
AlarmSink()
Constructs an
AlarmSink . |
AlarmSink(Cdb cdb)
Deprecated.
|
AlarmSink(Maapi maapi)
Construct an
AlarmSink using the given Maapi
object for writing alarms directly to the alarm list. |
Modifier and Type | Method and Description |
---|---|
void |
submitAlarm(Alarm alarm)
Submits the specified
Alarm into the alarm list. |
boolean |
submitAlarm(ManagedDevice managedDevice,
ManagedObject managedObject,
ConfIdentityRef alarmtype,
ConfBuf specificProblem,
PerceivedSeverity severity,
ConfBuf alarmText,
List<ManagedObject> impactedObjects,
List<AlarmId> relatedAlarms,
List<ManagedObject> rootCauseObjects,
ConfDatetime timeStamp,
Attribute... customAttributes)
Submits the specified
Alarm into the alarm list. |
boolean |
submitAlarm(ManagedDevice managedDevice,
ManagedObject managedObject,
ConfIdentityRef alarmtype,
ConfBuf specificProblem,
PerceivedSeverity severity,
String alarmText,
List<ManagedObject> impactedObjects,
List<AlarmId> relatedAlarms,
List<ManagedObject> rootCauseObjects,
ConfDatetime timeStamp,
Attribute... customAttributes)
Submits the specified
Alarm into the alarm list. |
@Deprecated public AlarmSink(Cdb cdb)
AlarmSink
using the given
Cdb
object for writing alarms directly.
Note: This constructor shall be the preferred constructor
used if you are not writing alarms inside the NCS JVM i.e
in a package component.
The AlarmSink
is standalone and does not
use the AlarmSinkCentral
.
cdb
- object to be used for writing alarmspublic AlarmSink(Maapi maapi) throws NavuException
AlarmSink
using the given Maapi
object for writing alarms directly to the alarm list.
Note: This constructor shall be the preferred constructor
used if you are not writing alarms inside the NCS JVM i.e
in a package component.
The AlarmSink
is standalone and does not
use the AlarmSinkCentral
.
maapi
- object to be used for writing alarmsNavuException
public AlarmSink()
AlarmSink
. This sink
writes alarms to the NCS indirectly using the central
AlarmSinkCentral
.
Note: This constructor shall be the preferred constructor used if you are writing alarms inside the NCS JVM i.e in a package component.
public void submitAlarm(Alarm alarm) throws NavuException, ConfException, IOException
Alarm
into the alarm list.
If the alarm's key
"managedDevice, managedObject, alarmType, specificProblem" already
exists, the existing alarm will be updated with a
new status change entry.alarm
- The alarm to be written to the alarm listNavuException
ConfException
IOException
public boolean submitAlarm(ManagedDevice managedDevice, ManagedObject managedObject, ConfIdentityRef alarmtype, ConfBuf specificProblem, PerceivedSeverity severity, String alarmText, List<ManagedObject> impactedObjects, List<AlarmId> relatedAlarms, List<ManagedObject> rootCauseObjects, ConfDatetime timeStamp, Attribute... customAttributes) throws NavuException, ConfException, IOException
Alarm
into the alarm list.
If the alarm's key
"managedDevice, managedObject, alarmType, specificProblem" already
exists, the existing alarm will be updated with a
new status change entry.
Alarm identity:managedDevice
- the managed device which emits the alarm.managedObject
- the managed object emitting the alarm.alarmtype
- the alarm type of the alarm.specificProblem
- is used when the alarmtype cannot uniquely
identify the alarm type. Normally, this is not the case,
and this leaf is the empty string.
Status change within the alarm:severity
- the severity of the alarm.alarmText
- the alarm textimpactedObjects
- Objects that might be affected by this alarmrelatedAlarms
- Alarms related to this alarmrootCauseObjects
- Objects that are candidates for causing the
alarm.timeStamp
- The time the status of the alarm changed,
as reported by the devicecustomAttributes
- Custom attributesIOException
ConfException
NavuException
public boolean submitAlarm(ManagedDevice managedDevice, ManagedObject managedObject, ConfIdentityRef alarmtype, ConfBuf specificProblem, PerceivedSeverity severity, ConfBuf alarmText, List<ManagedObject> impactedObjects, List<AlarmId> relatedAlarms, List<ManagedObject> rootCauseObjects, ConfDatetime timeStamp, Attribute... customAttributes) throws NavuException, ConfException, IOException
Alarm
into the alarm list.
If the alarms key
"managedDevice, managedObject, alarmType, specificProblem" already
exists, the existing alarm will be updated with a
new status change entry.
Alarm identity:managedDevice
- the managed device which emits the alarm.managedObject
- the managed object emitting the alarm.alarmtype
- the alarm type of the alarm.specificProblem
- is used when the alarmtype cannot uniquely
identify the alarm type. Normally, this is not the case,
and this leaf is the empty string.
Status change within the alarm:severity
- the severity of the alarm.alarmText
- the alarm textimpactedObjects
- Objects that might be affected by this alarmrelatedAlarms
- Alarms related to this alarmrootCauseObjects
- Objects that are candidates for causing the
alarm.timeStamp
- The time the status of the alarm changed,
as reported by the devicecustomAttributes
- Custom attributesIOException
ConfException
NavuException