# LimitsPerLabelSetProperty

This defines a label set for the workspace, and defines the ingestion limit for active time series that match that label set.

Each label name in a label set must be unique.

- Source: Generated at build time
- Type last changed: v2.191.0 · 23 Apr 2025

## Example

TypeScript:

```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 limitsPerLabelSetProperty: aps.CfnWorkspace.LimitsPerLabelSetProperty = {
  labelSet: [{
    name: 'name',
    value: 'value',
  }],
  limits: {
    maxSeries: 123,
  },
};
```

Python:

```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

limits_per_label_set_property = aps.CfnWorkspace.LimitsPerLabelSetProperty(
    label_set=[aps.CfnWorkspace.LabelProperty(
        name="name",
        value="value"
    )],
    limits=aps.CfnWorkspace.LimitsPerLabelSetEntryProperty(
        max_series=123
    )
)
```

Java:

```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.*;

LimitsPerLabelSetProperty limitsPerLabelSetProperty = LimitsPerLabelSetProperty.builder()
        .labelSet(List.of(LabelProperty.builder()
                .name("name")
                .value("value")
                .build()))
        .limits(LimitsPerLabelSetEntryProperty.builder()
                .maxSeries(123)
                .build())
        .build();
```

C# / .NET:

```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 limitsPerLabelSetProperty = new LimitsPerLabelSetProperty {
    LabelSet = new [] { new LabelProperty {
        Name = "name",
        Value = "value"
    } },
    Limits = new LimitsPerLabelSetEntryProperty {
        MaxSeries = 123
    }
};
```

Golang:

```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"

limitsPerLabelSetProperty := &LimitsPerLabelSetProperty{
	LabelSet: []interface{}{
		&LabelProperty{
			Name: jsii.String("name"),
			Value: jsii.String("value"),
		},
	},
	Limits: &LimitsPerLabelSetEntryProperty{
		MaxSeries: jsii.Number(123),
	},
}
```

## Properties

- `labelSet`: [IResolvable](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.IResolvable.html) | [IResolvable](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.IResolvable.html) | [CfnWorkspace.LabelProperty](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnWorkspace.LabelProperty.html)[] (required) — This defines one label set that will have an enforced ingestion limit.

  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.

  Label values accept all UTF-8 characters with one exception. If the label name is metric name label `__ *name* __` , then the *metric* part of the name must conform to the following pattern: `[a-zA-Z_:][a-zA-Z0-9_:]*`

- `limits`: [IResolvable](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.IResolvable.html) | [CfnWorkspace.LimitsPerLabelSetEntryProperty](https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_aps.CfnWorkspace.LimitsPerLabelSetEntryProperty.html) (required) — This structure contains the information about the limits that apply to time series that match this label set.
