CfnLinkProps
- class aws_cdk.aws_oam.CfnLinkProps(*, resource_types, sink_identifier, label_template=None, link_configuration=None, tags=None)
Bases:
objectProperties for defining a
CfnLink.- Parameters:
resource_types (
Sequence[str]) – An array of strings that define which types of data that the source account shares with the monitoring account. Valid values areAWS::CloudWatch::Metric | AWS::Logs::LogGroup | AWS::XRay::Trace | AWS::ApplicationInsights::Application | AWS::InternetMonitor::Monitor.sink_identifier (
str) – The ARN of the sink in the monitoring account that you want to link to. You can use ListSinks to find the ARNs of sinks.label_template (
Optional[str]) – Specify a friendly human-readable name to use to identify this source account when you are viewing data from it in the monitoring account. You can include the following variables in your template: -$AccountNameis the name of the account -$AccountEmailis a globally-unique email address, which includes the email domain, such asmariagarcia@example.com-$AccountEmailNoDomainis an email address without the domain name, such asmariagarcia.. epigraph:: In the and Regions, the only supported option is to use custom labels, and the$AccountName,$AccountEmail, and$AccountEmailNoDomainvariables all resolve as account-id instead of the specified variable.link_configuration (
Union[IResolvable,LinkConfigurationProperty,Dict[str,Any],None]) – 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.tags (
Optional[Mapping[str,str]]) – An array of key-value pairs to apply to the link. For more information, see Tag .
- See:
http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-oam-link.html
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. from aws_cdk import aws_oam as oam cfn_link_props = oam.CfnLinkProps( resource_types=["resourceTypes"], sink_identifier="sinkIdentifier", # the properties below are optional label_template="labelTemplate", link_configuration=oam.CfnLink.LinkConfigurationProperty( log_group_configuration=oam.CfnLink.LinkFilterProperty( filter="filter" ), metric_configuration=oam.CfnLink.LinkFilterProperty( filter="filter" ) ), tags={ "tags_key": "tags" } )
Attributes
- label_template
Specify a friendly human-readable name to use to identify this source account when you are viewing data from it in the monitoring account.
You can include the following variables in your template:
$AccountNameis the name of the account$AccountEmailis a globally-unique email address, which includes the email domain, such asmariagarcia@example.com$AccountEmailNoDomainis an email address without the domain name, such asmariagarcia
In the and Regions, the only supported option is to use custom labels, and the
$AccountName,$AccountEmail, and$AccountEmailNoDomainvariables all resolve as account-id instead of the specified variable.
- link_configuration
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.
- resource_types
An array of strings that define which types of data that the source account shares with the monitoring account.
Valid values are
AWS::CloudWatch::Metric | AWS::Logs::LogGroup | AWS::XRay::Trace | AWS::ApplicationInsights::Application | AWS::InternetMonitor::Monitor.
- sink_identifier
The ARN of the sink in the monitoring account that you want to link to.
You can use ListSinks to find the ARNs of sinks.