Class CfnSafetyRule
A CloudFormation AWS::Route53RecoveryControl::SafetyRule
.
Inherited Members
Namespace: Amazon.CDK.AWS.Route53RecoveryControl
Assembly: Amazon.CDK.AWS.Route53RecoveryControl.dll
Syntax (csharp)
public class CfnSafetyRule : CfnResource, IConstruct, IDependable, IInspectable
Syntax (vb)
Public Class CfnSafetyRule
Inherits CfnResource
Implements IConstruct, IDependable, IInspectable
Remarks
Creates a safety rule in a control panel in Amazon Route 53 Application Recovery Controller. Safety rules in Amazon Route 53 Application Recovery Controller let you add safeguards around changing routing control states, and enabling and disabling routing controls, to help prevent unwanted outcomes. Note that the name of a safety rule must be unique within a control panel.
There are two types of safety rules in Route 53 ARC: assertion rules and gating rules.
Assertion rule: An assertion rule enforces that, when you change a routing control state, certain criteria are met. For example, the criteria might be that at least one routing control state is On
after the transaction completes so that traffic continues to be directed to at least one cell for the application. This prevents a fail-open scenario.
Gating rule: A gating rule lets you configure a gating routing control as an overall on-off switch for a group of routing controls. Or, you can configure more complex gating scenarios, for example, by configuring multiple gating routing controls.
For more information, see Safety rules in the Amazon Route 53 Application Recovery Controller Developer Guide.
CloudformationResource: AWS::Route53RecoveryControl::SafetyRule
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.Route53RecoveryControl;
var cfnSafetyRule = new CfnSafetyRule(this, "MyCfnSafetyRule", new CfnSafetyRuleProps {
ControlPanelArn = "controlPanelArn",
Name = "name",
RuleConfig = new RuleConfigProperty {
Inverted = false,
Threshold = 123,
Type = "type"
},
// the properties below are optional
AssertionRule = new AssertionRuleProperty {
AssertedControls = new [] { "assertedControls" },
WaitPeriodMs = 123
},
GatingRule = new GatingRuleProperty {
GatingControls = new [] { "gatingControls" },
TargetControls = new [] { "targetControls" },
WaitPeriodMs = 123
},
Tags = new [] { new CfnTag {
Key = "key",
Value = "value"
} }
});
Synopsis
Constructors
CfnSafetyRule(Construct, String, ICfnSafetyRuleProps) | Create a new |
CfnSafetyRule(ByRefValue) | Used by jsii to construct an instance of this class from a Javascript-owned object reference |
CfnSafetyRule(DeputyBase.DeputyProps) | Used by jsii to construct an instance of this class from DeputyProps |
Properties
AssertionRule | An assertion rule enforces that, when you change a routing control state, that the criteria that you set in the rule configuration is met. |
AttrSafetyRuleArn | The Amazon Resource Name (ARN) of the safety rule. |
AttrStatus | The deployment status of the safety rule. |
CFN_RESOURCE_TYPE_NAME | The CloudFormation resource type name for this resource class. |
CfnProperties | |
ControlPanelArn | The Amazon Resource Name (ARN) for the control panel. |
GatingRule | A gating rule verifies that a gating routing control or set of gating routing controls, evaluates as true, based on a rule configuration that you specify, which allows a set of routing control state changes to complete. |
Name | The name of the assertion rule. |
RuleConfig | The criteria that you set for specific assertion controls (routing controls) that designate how many control states must be |
Tags | The value for a tag. |
Methods
Inspect(TreeInspector) | Examines the CloudFormation resource and discloses attributes. |
RenderProperties(IDictionary<String, Object>) |
Constructors
CfnSafetyRule(Construct, String, ICfnSafetyRuleProps)
Create a new AWS::Route53RecoveryControl::SafetyRule
.
public CfnSafetyRule(Construct scope, string id, ICfnSafetyRuleProps props)
Parameters
- scope Construct
- scope in which this resource is defined.
- id System.String
- scoped id of the resource.
- props ICfnSafetyRuleProps
- resource properties.
CfnSafetyRule(ByRefValue)
Used by jsii to construct an instance of this class from a Javascript-owned object reference
protected CfnSafetyRule(ByRefValue reference)
Parameters
- reference Amazon.JSII.Runtime.Deputy.ByRefValue
The Javascript-owned object reference
CfnSafetyRule(DeputyBase.DeputyProps)
Used by jsii to construct an instance of this class from DeputyProps
protected CfnSafetyRule(DeputyBase.DeputyProps props)
Parameters
- props Amazon.JSII.Runtime.Deputy.DeputyBase.DeputyProps
The deputy props
Properties
AssertionRule
An assertion rule enforces that, when you change a routing control state, that the criteria that you set in the rule configuration is met.
public virtual object AssertionRule { get; set; }
Property Value
System.Object
Remarks
Otherwise, the change to the routing control is not accepted. For example, the criteria might be that at least one routing control state is On
after the transaction so that traffic continues to flow to at least one cell for the application. This ensures that you avoid a fail-open scenario.
AttrSafetyRuleArn
The Amazon Resource Name (ARN) of the safety rule.
public virtual string AttrSafetyRuleArn { get; }
Property Value
System.String
Remarks
CloudformationAttribute: SafetyRuleArn
AttrStatus
The deployment status of the safety rule.
public virtual string AttrStatus { get; }
Property Value
System.String
Remarks
Status can be one of the following: PENDING, DEPLOYED, PENDING_DELETION.
CloudformationAttribute: Status
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
ControlPanelArn
The Amazon Resource Name (ARN) for the control panel.
public virtual string ControlPanelArn { get; set; }
Property Value
System.String
Remarks
GatingRule
A gating rule verifies that a gating routing control or set of gating routing controls, evaluates as true, based on a rule configuration that you specify, which allows a set of routing control state changes to complete.
public virtual object GatingRule { get; set; }
Property Value
System.Object
Remarks
For example, if you specify one gating routing control and you set the Type
in the rule configuration to OR
, that indicates that you must set the gating routing control to On
for the rule to evaluate as true; that is, for the gating control switch to be On. When you do that, then you can update the routing control states for the target routing controls that you specify in the gating rule.
Name
The name of the assertion rule.
public virtual string Name { get; set; }
Property Value
System.String
Remarks
The name must be unique within a control panel. You can use any non-white space character in the name except the following: & > < ' (single quote) " (double quote) ; (semicolon)
RuleConfig
The criteria that you set for specific assertion controls (routing controls) that designate how many control states must be ON
as the result of a transaction.
public virtual object RuleConfig { get; set; }
Property Value
System.Object
Remarks
For example, if you have three assertion controls, you might specify ATLEAST 2
for your rule configuration. This means that at least two assertion controls must be ON
, so that at least two AWS Regions have traffic flowing to them.
Tags
The value for a tag.
public virtual TagManager Tags { get; }
Property Value
Remarks
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>