Class CfnAlarmModel
A CloudFormation AWS::IoTEvents::AlarmModel
.
Inherited Members
Namespace: Amazon.CDK.AWS.IoTEvents
Assembly: Amazon.CDK.AWS.IoTEvents.dll
Syntax (csharp)
public class CfnAlarmModel : CfnResource, IConstruct, IDependable, IInspectable
Syntax (vb)
Public Class CfnAlarmModel
Inherits CfnResource
Implements IConstruct, IDependable, IInspectable
Remarks
Represents an alarm model to monitor an AWS IoT Events input attribute. You can use the alarm to get notified when the value is outside a specified range. For more information, see Create an alarm model in the AWS IoT Events Developer Guide .
CloudformationResource: AWS::IoTEvents::AlarmModel
Link: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-iotevents-alarmmodel.html
ExampleMetadata: fixture=_generated
Examples
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.IoTEvents;
var cfnAlarmModel = new CfnAlarmModel(this, "MyCfnAlarmModel", new CfnAlarmModelProps {
AlarmRule = new AlarmRuleProperty {
SimpleRule = new SimpleRuleProperty {
ComparisonOperator = "comparisonOperator",
InputProperty = "inputProperty",
Threshold = "threshold"
}
},
RoleArn = "roleArn",
// the properties below are optional
AlarmCapabilities = new AlarmCapabilitiesProperty {
AcknowledgeFlow = new AcknowledgeFlowProperty {
Enabled = false
},
InitializationConfiguration = new InitializationConfigurationProperty {
DisabledOnInitialization = false
}
},
AlarmEventActions = new AlarmEventActionsProperty {
AlarmActions = new [] { new AlarmActionProperty {
DynamoDb = new DynamoDBProperty {
HashKeyField = "hashKeyField",
HashKeyValue = "hashKeyValue",
TableName = "tableName",
// the properties below are optional
HashKeyType = "hashKeyType",
Operation = "operation",
Payload = new PayloadProperty {
ContentExpression = "contentExpression",
Type = "type"
},
PayloadField = "payloadField",
RangeKeyField = "rangeKeyField",
RangeKeyType = "rangeKeyType",
RangeKeyValue = "rangeKeyValue"
},
DynamoDBv2 = new DynamoDBv2Property {
TableName = "tableName",
// the properties below are optional
Payload = new PayloadProperty {
ContentExpression = "contentExpression",
Type = "type"
}
},
Firehose = new FirehoseProperty {
DeliveryStreamName = "deliveryStreamName",
// the properties below are optional
Payload = new PayloadProperty {
ContentExpression = "contentExpression",
Type = "type"
},
Separator = "separator"
},
IotEvents = new IotEventsProperty {
InputName = "inputName",
// the properties below are optional
Payload = new PayloadProperty {
ContentExpression = "contentExpression",
Type = "type"
}
},
IotSiteWise = new IotSiteWiseProperty {
AssetId = "assetId",
EntryId = "entryId",
PropertyAlias = "propertyAlias",
PropertyId = "propertyId",
PropertyValue = new AssetPropertyValueProperty {
Value = new AssetPropertyVariantProperty {
BooleanValue = "booleanValue",
DoubleValue = "doubleValue",
IntegerValue = "integerValue",
StringValue = "stringValue"
},
// the properties below are optional
Quality = "quality",
Timestamp = new AssetPropertyTimestampProperty {
TimeInSeconds = "timeInSeconds",
// the properties below are optional
OffsetInNanos = "offsetInNanos"
}
}
},
IotTopicPublish = new IotTopicPublishProperty {
MqttTopic = "mqttTopic",
// the properties below are optional
Payload = new PayloadProperty {
ContentExpression = "contentExpression",
Type = "type"
}
},
Lambda = new LambdaProperty {
FunctionArn = "functionArn",
// the properties below are optional
Payload = new PayloadProperty {
ContentExpression = "contentExpression",
Type = "type"
}
},
Sns = new SnsProperty {
TargetArn = "targetArn",
// the properties below are optional
Payload = new PayloadProperty {
ContentExpression = "contentExpression",
Type = "type"
}
},
Sqs = new SqsProperty {
QueueUrl = "queueUrl",
// the properties below are optional
Payload = new PayloadProperty {
ContentExpression = "contentExpression",
Type = "type"
},
UseBase64 = false
}
} }
},
AlarmModelDescription = "alarmModelDescription",
AlarmModelName = "alarmModelName",
Key = "key",
Severity = 123,
Tags = new [] { new CfnTag {
Key = "key",
Value = "value"
} }
});
Synopsis
Constructors
CfnAlarmModel(Construct, String, ICfnAlarmModelProps) | Create a new |
CfnAlarmModel(ByRefValue) | Used by jsii to construct an instance of this class from a Javascript-owned object reference |
CfnAlarmModel(DeputyBase.DeputyProps) | Used by jsii to construct an instance of this class from DeputyProps |
Properties
AlarmCapabilities | Contains the configuration information of alarm state changes. |
AlarmEventActions | Contains information about one or more alarm actions. |
AlarmModelDescription | The description of the alarm model. |
AlarmModelName | The name of the alarm model. |
AlarmRule | Defines when your alarm is invoked. |
CFN_RESOURCE_TYPE_NAME | The CloudFormation resource type name for this resource class. |
CfnProperties | |
Key | An input attribute used as a key to create an alarm. |
RoleArn | The ARN of the IAM role that allows the alarm to perform actions and access AWS resources. |
Severity | A non-negative integer that reflects the severity level of the alarm. |
Tags | A list of key-value pairs that contain metadata for the alarm model. |
Methods
Inspect(TreeInspector) | Examines the CloudFormation resource and discloses attributes. |
RenderProperties(IDictionary<String, Object>) |
Constructors
CfnAlarmModel(Construct, String, ICfnAlarmModelProps)
Create a new AWS::IoTEvents::AlarmModel
.
public CfnAlarmModel(Construct scope, string id, ICfnAlarmModelProps props)
Parameters
- scope Construct
- scope in which this resource is defined.
- id System.String
- scoped id of the resource.
- props ICfnAlarmModelProps
- resource properties.
CfnAlarmModel(ByRefValue)
Used by jsii to construct an instance of this class from a Javascript-owned object reference
protected CfnAlarmModel(ByRefValue reference)
Parameters
- reference Amazon.JSII.Runtime.Deputy.ByRefValue
The Javascript-owned object reference
CfnAlarmModel(DeputyBase.DeputyProps)
Used by jsii to construct an instance of this class from DeputyProps
protected CfnAlarmModel(DeputyBase.DeputyProps props)
Parameters
- props Amazon.JSII.Runtime.Deputy.DeputyBase.DeputyProps
The deputy props
Properties
AlarmCapabilities
Contains the configuration information of alarm state changes.
public virtual object AlarmCapabilities { get; set; }
Property Value
System.Object
Remarks
AlarmEventActions
Contains information about one or more alarm actions.
public virtual object AlarmEventActions { get; set; }
Property Value
System.Object
Remarks
AlarmModelDescription
The description of the alarm model.
public virtual string AlarmModelDescription { get; set; }
Property Value
System.String
Remarks
AlarmModelName
The name of the alarm model.
public virtual string AlarmModelName { get; set; }
Property Value
System.String
Remarks
AlarmRule
Defines when your alarm is invoked.
public virtual object AlarmRule { get; set; }
Property Value
System.Object
Remarks
CFN_RESOURCE_TYPE_NAME
The CloudFormation resource type name for this resource class.
public static string CFN_RESOURCE_TYPE_NAME { get; }
Property Value
System.String
CfnProperties
protected override IDictionary<string, object> CfnProperties { get; }
Property Value
System.Collections.Generic.IDictionary<System.String, System.Object>
Overrides
Key
An input attribute used as a key to create an alarm.
public virtual string Key { get; set; }
Property Value
System.String
Remarks
AWS IoT Events routes inputs associated with this key to the alarm.
RoleArn
The ARN of the IAM role that allows the alarm to perform actions and access AWS resources.
public virtual string RoleArn { get; set; }
Property Value
System.String
Remarks
For more information, see Amazon Resource Names (ARNs) in the AWS General Reference .
Severity
A non-negative integer that reflects the severity level of the alarm.
public virtual Nullable<double> Severity { get; set; }
Property Value
System.Nullable<System.Double>
Remarks
Tags
A list of key-value pairs that contain metadata for the alarm model.
public virtual TagManager Tags { get; }
Property Value
Remarks
The tags help you manage the alarm model. For more information, see Tagging your AWS IoT Events resources in the AWS IoT Events Developer Guide .
You can create up to 50 tags for one alarm model.
Methods
Inspect(TreeInspector)
Examines the CloudFormation resource and discloses attributes.
public virtual void Inspect(TreeInspector inspector)
Parameters
- inspector TreeInspector
- tree inspector to collect and process attributes.
RenderProperties(IDictionary<String, Object>)
protected override IDictionary<string, object> RenderProperties(IDictionary<string, object> props)
Parameters
- props System.Collections.Generic.IDictionary<System.String, System.Object>
Returns
System.Collections.Generic.IDictionary<System.String, System.Object>