Class CfnLink
Creates a link between a source account and a sink that you have created in a monitoring account.
Inherited Members
Namespace: Amazon.CDK.AWS.Oam
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class CfnLink : CfnResource, IInspectable, ITaggable
Syntax (vb)
Public Class CfnLink
Inherits CfnResource
Implements IInspectable, ITaggable
Remarks
Before you create a link, you must create a sink in the monitoring account. The sink must have a sink policy that permits the source account to link to it. You can grant permission to source accounts by granting permission to an entire organization, an organizational unit, or to individual accounts.
For more information, see CreateSink and PutSinkPolicy .
Each monitoring account can be linked to as many as 100,000 source accounts.
Each source account can be linked to as many as five monitoring accounts.
See: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-oam-link.html
CloudformationResource: AWS::Oam::Link
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.Oam;
var cfnLink = new CfnLink(this, "MyCfnLink", new CfnLinkProps {
ResourceTypes = new [] { "resourceTypes" },
SinkIdentifier = "sinkIdentifier",
// the properties below are optional
LabelTemplate = "labelTemplate",
LinkConfiguration = new LinkConfigurationProperty {
LogGroupConfiguration = new LinkFilterProperty {
Filter = "filter"
},
MetricConfiguration = new LinkFilterProperty {
Filter = "filter"
}
},
Tags = new Dictionary<string, string> {
{ "tagsKey", "tags" }
}
});
Synopsis
Constructors
CfnLink(ByRefValue) | Used by jsii to construct an instance of this class from a Javascript-owned object reference |
CfnLink(DeputyBase.DeputyProps) | Used by jsii to construct an instance of this class from DeputyProps |
CfnLink(Construct, String, ICfnLinkProps) |
Properties
AttrArn | The ARN of the link. |
AttrLabel | The friendly human-readable name used to identify this source account when it is viewed from the monitoring account. |
CFN_RESOURCE_TYPE_NAME | The CloudFormation resource type name for this resource class. |
CfnProperties | |
LabelTemplate | Specify a friendly human-readable name to use to identify this source account when you are viewing data from it in the monitoring account. |
LinkConfiguration | Use this structure to optionally create filters that specify that only some metric namespaces or log groups are to be shared from the source account to the monitoring account. |
ResourceTypes | An array of strings that define which types of data that the source account shares with the monitoring account. |
SinkIdentifier | The ARN of the sink in the monitoring account that you want to link to. |
Tags | Tag Manager which manages the tags for this resource. |
TagsRaw | An array of key-value pairs to apply to the link. |
Methods
Inspect(TreeInspector) | Examines the CloudFormation resource and discloses attributes. |
RenderProperties(IDictionary<String, Object>) |
Constructors
CfnLink(ByRefValue)
Used by jsii to construct an instance of this class from a Javascript-owned object reference
protected CfnLink(ByRefValue reference)
Parameters
- reference Amazon.JSII.Runtime.Deputy.ByRefValue
The Javascript-owned object reference
CfnLink(DeputyBase.DeputyProps)
Used by jsii to construct an instance of this class from DeputyProps
protected CfnLink(DeputyBase.DeputyProps props)
Parameters
- props Amazon.JSII.Runtime.Deputy.DeputyBase.DeputyProps
The deputy props
CfnLink(Construct, String, ICfnLinkProps)
public CfnLink(Construct scope, string id, ICfnLinkProps props)
Parameters
- scope Constructs.Construct
Scope in which this resource is defined.
- id System.String
Construct identifier for this resource (unique in its scope).
- props ICfnLinkProps
Resource properties.
Properties
AttrArn
The ARN of the link.
public virtual string AttrArn { get; }
Property Value
System.String
Remarks
For example, arn:aws:oam:us-west-1:111111111111:link:abcd1234-a123-456a-a12b-a123b456c789
CloudformationAttribute: Arn
AttrLabel
The friendly human-readable name used to identify this source account when it is viewed from the monitoring account.
public virtual string AttrLabel { get; }
Property Value
System.String
Remarks
For example, my-account1
.
CloudformationAttribute: Label
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
LabelTemplate
Specify a friendly human-readable name to use to identify this source account when you are viewing data from it in the monitoring account.
public virtual string LabelTemplate { get; set; }
Property Value
System.String
LinkConfiguration
Use this structure to optionally create filters that specify that only some metric namespaces or log groups are to be shared from the source account to the monitoring account.
public virtual object LinkConfiguration { get; set; }
Property Value
System.Object
ResourceTypes
An array of strings that define which types of data that the source account shares with the monitoring account.
public virtual string[] ResourceTypes { get; set; }
Property Value
System.String[]
SinkIdentifier
The ARN of the sink in the monitoring account that you want to link to.
public virtual string SinkIdentifier { get; set; }
Property Value
System.String
Tags
Tag Manager which manages the tags for this resource.
public virtual TagManager Tags { get; }
Property Value
TagsRaw
An array of key-value pairs to apply to the link.
public virtual IDictionary<string, string> TagsRaw { get; set; }
Property Value
System.Collections.Generic.IDictionary<System.String, System.String>
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>