FrameworkBase.InsertAlerts Method
Creates and adds new alerts to MOM.
public abstract Alert[] FrameworkBase.InsertAlerts(
Guid registrationId,
Alert[] alerts
);
Parameters
- registrationId
The connector's registration ID. The registration ID is obtained from the initial call to the FrameworkBase.Setup method. - alerts
An array of Alert objects to insert.
Return Value
An array of new Alert objects to add.
Exceptions
Exception Type | Condition |
---|---|
System.UnauthorizedAccessException | The user account is not part of the LOCALMACHINE\MOM Service user group. |
System.InvalidOperationException | The registrationId value is valid. |
System.ArgumentException | One or more Alert objects are not valid. |
Remarks
To improve performance when inserting large numbers of alerts, send no more than 25 alerts in each call to the InsertAlerts method.
Alerts added to MOM using the InsertAlerts method are placed in a queue. Processing the alert can take up to two minutes. Until the processing is complete, the alert will not be visible from the user interface or any of the MOM APIs that return alerts.
Alerts added to MOM using this method are not associated with a rule, unlike conventional alerts. For more information about the consequences, and the role of Management Packs with connectors, see Using Management Packs with a Connector.
When calling this method, the Alert objects are serialized as XML data. Alert property values that contain characters that are considered invalid within XML should be handled before calling the method. For more information about character sets and XML, see section 2.2 of the Extensible Markup Language (XML) 1.0 (Second Edition) W3C recommendation.
Requirements
Platforms: Requires Windows 2000 Server or later
Version: Requires MOM 2000 SP1 or later
Namespace: Microsoft.EnterpriseManagement.Mom.Connector
Assembly: MomConnectorFramework (in MomConnectorFramework.dll)