Essentials Class

  • java.lang.Object
    • com.azure.resourcemanager.alertsmanagement.models.Essentials

Implements

public final class Essentials
implements JsonSerializable<Essentials>

This object contains consistent fields across different monitor services.

Constructor Summary

Constructor Description
Essentials()

Creates an instance of Essentials class.

Method Summary

Modifier and Type Method and Description
ActionStatus actionStatus()

Get the actionStatus property: Action status.

String alertRule()

Get the alertRule property: Rule(monitor) which fired alert instance.

AlertState alertState()

Get the alertState property: Alert object state, which can be modified by the user.

String description()

Get the description property: Alert description.

static Essentials fromJson(JsonReader jsonReader)

Reads an instance of Essentials from the JsonReader.

OffsetDateTime lastModifiedDateTime()

Get the lastModifiedDateTime property: Last modification time(ISO-8601 format) of alert instance.

String lastModifiedUsername()

Get the lastModifiedUsername property: User who last modified the alert, in case of monitor service updates user would be 'system', otherwise name of the user.

MonitorCondition monitorCondition()

Get the monitorCondition property: Condition of the rule at the monitor service.

OffsetDateTime monitorConditionResolvedDateTime()

Get the monitorConditionResolvedDateTime property: Resolved time(ISO-8601 format) of alert instance.

MonitorService monitorService()

Get the monitorService property: Monitor service on which the rule(monitor) is set.

Severity severity()

Get the severity property: Severity of alert Sev0 being highest and Sev4 being lowest.

SignalType signalType()

Get the signalType property: The type of signal the alert is based on, which could be metrics, logs or activity logs.

String smartGroupId()

Get the smartGroupId property: Unique Id of the smart group.

String smartGroupingReason()

Get the smartGroupingReason property: Verbose reason describing the reason why this alert instance is added to a smart group.

String sourceCreatedId()

Get the sourceCreatedId property: Unique Id created by monitor service for each alert instance.

OffsetDateTime startDateTime()

Get the startDateTime property: Creation time(ISO-8601 format) of alert instance.

String targetResource()

Get the targetResource property: Target ARM resource, on which alert got created.

String targetResourceGroup()

Get the targetResourceGroup property: Resource group of target ARM resource, on which alert got created.

String targetResourceName()

Get the targetResourceName property: Name of the target ARM resource name, on which alert got created.

String targetResourceType()

Get the targetResourceType property: Resource type of target ARM resource, on which alert got created.

JsonWriter toJson(JsonWriter jsonWriter)
void validate()

Validates the instance.

Essentials withActionStatus(ActionStatus actionStatus)

Set the actionStatus property: Action status.

Essentials withDescription(String description)

Set the description property: Alert description.

Essentials withTargetResource(String targetResource)

Set the targetResource property: Target ARM resource, on which alert got created.

Essentials withTargetResourceGroup(String targetResourceGroup)

Set the targetResourceGroup property: Resource group of target ARM resource, on which alert got created.

Essentials withTargetResourceName(String targetResourceName)

Set the targetResourceName property: Name of the target ARM resource name, on which alert got created.

Essentials withTargetResourceType(String targetResourceType)

Set the targetResourceType property: Resource type of target ARM resource, on which alert got created.

Methods inherited from java.lang.Object

Constructor Details

Essentials

public Essentials()

Creates an instance of Essentials class.

Method Details

actionStatus

public ActionStatus actionStatus()

Get the actionStatus property: Action status.

Returns:

the actionStatus value.

alertRule

public String alertRule()

Get the alertRule property: Rule(monitor) which fired alert instance. Depending on the monitor service, this would be ARM id or name of the rule.

Returns:

the alertRule value.

alertState

public AlertState alertState()

Get the alertState property: Alert object state, which can be modified by the user.

Returns:

the alertState value.

description

public String description()

Get the description property: Alert description.

Returns:

the description value.

fromJson

public static Essentials fromJson(JsonReader jsonReader)

Reads an instance of Essentials from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

An instance of Essentials if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.

Throws:

IOException

- If an error occurs while reading the Essentials.

lastModifiedDateTime

public OffsetDateTime lastModifiedDateTime()

Get the lastModifiedDateTime property: Last modification time(ISO-8601 format) of alert instance.

Returns:

the lastModifiedDateTime value.

lastModifiedUsername

public String lastModifiedUsername()

Get the lastModifiedUsername property: User who last modified the alert, in case of monitor service updates user would be 'system', otherwise name of the user.

Returns:

the lastModifiedUsername value.

monitorCondition

public MonitorCondition monitorCondition()

Get the monitorCondition property: Condition of the rule at the monitor service. It represents whether the underlying conditions have crossed the defined alert rule thresholds.

Returns:

the monitorCondition value.

monitorConditionResolvedDateTime

public OffsetDateTime monitorConditionResolvedDateTime()

Get the monitorConditionResolvedDateTime property: Resolved time(ISO-8601 format) of alert instance. This will be updated when monitor service resolves the alert instance because the rule condition is no longer met.

Returns:

the monitorConditionResolvedDateTime value.

monitorService

public MonitorService monitorService()

Get the monitorService property: Monitor service on which the rule(monitor) is set.

Returns:

the monitorService value.

severity

public Severity severity()

Get the severity property: Severity of alert Sev0 being highest and Sev4 being lowest.

Returns:

the severity value.

signalType

public SignalType signalType()

Get the signalType property: The type of signal the alert is based on, which could be metrics, logs or activity logs.

Returns:

the signalType value.

smartGroupId

public String smartGroupId()

Get the smartGroupId property: Unique Id of the smart group.

Returns:

the smartGroupId value.

smartGroupingReason

public String smartGroupingReason()

Get the smartGroupingReason property: Verbose reason describing the reason why this alert instance is added to a smart group.

Returns:

the smartGroupingReason value.

sourceCreatedId

public String sourceCreatedId()

Get the sourceCreatedId property: Unique Id created by monitor service for each alert instance. This could be used to track the issue at the monitor service, in case of Nagios, Zabbix, SCOM etc.

Returns:

the sourceCreatedId value.

startDateTime

public OffsetDateTime startDateTime()

Get the startDateTime property: Creation time(ISO-8601 format) of alert instance.

Returns:

the startDateTime value.

targetResource

public String targetResource()

Get the targetResource property: Target ARM resource, on which alert got created.

Returns:

the targetResource value.

targetResourceGroup

public String targetResourceGroup()

Get the targetResourceGroup property: Resource group of target ARM resource, on which alert got created.

Returns:

the targetResourceGroup value.

targetResourceName

public String targetResourceName()

Get the targetResourceName property: Name of the target ARM resource name, on which alert got created.

Returns:

the targetResourceName value.

targetResourceType

public String targetResourceType()

Get the targetResourceType property: Resource type of target ARM resource, on which alert got created.

Returns:

the targetResourceType value.

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

validate

public void validate()

Validates the instance.

withActionStatus

public Essentials withActionStatus(ActionStatus actionStatus)

Set the actionStatus property: Action status.

Parameters:

actionStatus - the actionStatus value to set.

Returns:

the Essentials object itself.

withDescription

public Essentials withDescription(String description)

Set the description property: Alert description.

Parameters:

description - the description value to set.

Returns:

the Essentials object itself.

withTargetResource

public Essentials withTargetResource(String targetResource)

Set the targetResource property: Target ARM resource, on which alert got created.

Parameters:

targetResource - the targetResource value to set.

Returns:

the Essentials object itself.

withTargetResourceGroup

public Essentials withTargetResourceGroup(String targetResourceGroup)

Set the targetResourceGroup property: Resource group of target ARM resource, on which alert got created.

Parameters:

targetResourceGroup - the targetResourceGroup value to set.

Returns:

the Essentials object itself.

withTargetResourceName

public Essentials withTargetResourceName(String targetResourceName)

Set the targetResourceName property: Name of the target ARM resource name, on which alert got created.

Parameters:

targetResourceName - the targetResourceName value to set.

Returns:

the Essentials object itself.

withTargetResourceType

public Essentials withTargetResourceType(String targetResourceType)

Set the targetResourceType property: Resource type of target ARM resource, on which alert got created.

Parameters:

targetResourceType - the targetResourceType value to set.

Returns:

the Essentials object itself.

Applies to