Skip to content
v2.278.0

LabelProperty Struct ​

A label is a name:value pair used to add context to ingested metrics.

This structure defines the name and value for one label that is used in a label set. You can set ingestion limits on time series that match defined label sets, to help prevent a workspace from being overwhelmed with unexpected spikes in time series ingestion.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_aps as aps } from 'aws-cdk-lib';
const labelProperty: aps.CfnWorkspace.LabelProperty = {
  name: 'name',
  value: 'value',
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_aps as aps

label_property = aps.CfnWorkspace.LabelProperty(
    name="name",
    value="value"
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.aps.*;

LabelProperty labelProperty = LabelProperty.builder()
        .name("name")
        .value("value")
        .build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.APS;

var labelProperty = new LabelProperty {
    Name = "name",
    Value = "value"
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"

labelProperty := &LabelProperty{
	Name: jsii.String("name"),
	Value: jsii.String("value"),
}

Properties ​

namestringnamestrnameStringNamestringName*string required #
The name for this label.
valuestringvaluestrvalueStringValuestringValue*string required #
The value for this label.