Labels in Nobl9
Labels are key-value pairs that you can add to SLOs, services, projects, alert policies, and annotations in the Nobl9 platform. With labels, you can define attributes for these resources and use labels for resource filtering and grouping. For example, labels allow you to:
- Search and filter SLOs in the Service level objectives section and on the Service Health Dashboard
- Select specific SLOs to include in reports
- Filter annotations and create custom columns in the Events section
Labels are attached to resources during resource creation or editing. You can select existing pre-defined labels or add new ones that are specific to your organization.
The Catalog section lists all labels existing in an organization.
You can also use Nobl9 metadata annotations to add custom non-identifying metadata to SLOs,
services, projects, and alert policies using sloctl
and Nobl9 SDK for Go!.
Read about differences between labels and metadata annotations.
Requirements for labels
Labels have a specific format and must conform to the following rules:
- Must follow the
key: value
format (key=value
insloctl
):key
can contain only lowercase letters, digits0-9
, underscores_
, and hyphens-
. Start with a letter. End with a letter or digit.
The maximum length is 63 charactersvalue
can contain Unicode characters.
The maximum length is 200 characters
- Can contain international (diacritic) characters
- Can contain digits (
0-9
), underscores (_
) and hyphens (-
) between the letters - Maximum 20 labels per resource
Setting units for SLI charts
Labels for chart units must meet the common requirements.
You can add a unit label to be displayed on the SLI graph under SLO details at Step 5 of the SLO wizard as follows:
- Enter the unit
key
-value
pair. For example,unit: ms
.

- Save your changes. To view the unit you've added, go to your SLO details. Find the unit above the Y-axis of the SLI chart:

Label management
You can create labels by adding them to SLOs, services, projects, alert policies, and annotations.
To create a label in the Nobl9 Web application, go to the required resource wizard:
- Go to the required section of the Nobl9 web application.
- Add a new resource or annotation or edit start editing an existing one.
- In the Labels field, enter a new
key
andvalue
. - Click
in the field to save your new label.
Alternatively, select the available key and value to label this resource or annotation.
To unlink unnecessary labels from resources or annotations in the Nobl9 web app, do one of the following:
- Start editing your required resource or annotation.
- Go to Catalog > Labels. Unlink the label from any resource under your required label details.
Label list
You can access all labels available for your organization under Catalog > Labels:

The following options are available:
- View
key-value
pairs and resources per every label - Search labels by
key
andvalue
- Sort labels by
key
and usage - Edit individual labels
- Delete individual labels
- Open the selected label details
Label details
Under the label details, you can view resources that are labeled with it and remove this label from the associated resources.

The resource tabs display only resources you can access.
This means you can see fewer resources per label than it's specified in this label summary (the right-side block under the label details) or in the Catalog > Labels.
Retrieving labeled resources with sloctl
Retrieving a labeled resource also returns associated labels.
Use the -l
flag to filter the retrieved resources by label as follows:
-
Separate labels by comma without spaces. For example,
sloctl get slos -A -l key1=value1,key2=value2,key3=value3
-
Separate labels by the
-l
flag separating the required labels with spaces. For example,sloctl get slos -A -l team=green -l region=eu -l customer-type=enterprise
Filtering labeled resources with sloctl
follows the same logic as in the Nobl9 Web application.
RBAC
Action | Access level required | Result |
---|---|---|
Unlink label | Project owner or editor | The key: value pair remains in the organization, but it's unlinked from a resource |
Delete label | Organization admin | The key: value pair no longer exists in the organization |
Labels vs. metadata annotations
The difference between labels and metadata annotations is as follows:
- Labels identify objects and locate groups of objects that meet specific criteria.
- You can add labels using Nobl9 web app,
sloctl
, Nobl9 API, Nobl9 Terraform provider, or Nobl9 SDK for Go!.
- You can add labels using Nobl9 web app,
- Metadata annotations don't serve the purpose of object identification or selection.
- You can add or retrieve metadata annotations only using
sloctl
or Nobl9 SDK for Go!
- You can add or retrieve metadata annotations only using
- You can apply both labels and metadata annotations to the same Nobl9 resource.
The following table summarizes differences between labels and metadata annotations:
Capability | Labels | Metadata annotations |
---|---|---|
Resource identification | Identify Nobl9 resources based on specific criteria. Use for grouping and filtering | Do not identify Nobl9 objects. Use to add context |
Handling labels | sloctl | sloctl |
Label syntax | key: - list-of-values | key: value |
Character limit for value | Up to 200 unicode characters | Up to 1050 unicode characters |
metadata.annotations
and kind: Annotation
metadata.annotations
differ from SLO annotations.
SLO annotations are defined as a standalone YAML kind
, associated with SLOs as event notes. They include defined start and end times and are visible on the Nobl9 Web.