Type to search.

Metadata

Serverless

Elastic Cloud Serverless projects are autoscaled environments, fully managed by Elastic and available on Elastic Cloud.

Availability

  • Generally available

    This functionality is generally available and ready for production usage.

Serverless interfaces and procedures might differ from classic Elastic Stack deployments.

Stack

The Elastic Stack includes Elastic's core products such as Elasticsearch, Kibana, Logstash, and Beats.

Availability

  • Generally available

    This functionality is generally available and ready for production usage.

Unless stated otherwise on the page, this functionality is available when your Elastic Stack is deployed on Elastic Cloud Hosted, Elastic Cloud Enterprise, Elastic Cloud on Kubernetes, and self-managed environments.

This documentation corresponds to the latest patch available for each minor version. If you're not using the latest patch, check the release notes for changes.

Metadata can enrich your events and make application performance monitoring even more useful. Let’s explore the different types of metadata that Elastic APM offers.

Note

If you’re using OpenTelemetry SDKs, refer to OpenTelemetry attributes to learn how to add attributes to your telemetry data.

Labels add indexed information to transactions, spans, and errors. Indexed means the data is searchable and aggregatable in Elasticsearch. Add additional key-value pairs to define multiple labels.

Label values can be a string, boolean, or number, although some agents only support string values at this time. Because labels for a given key, regardless of agent used, are stored in the same place in Elasticsearch, all label values of a given key must have the same data type. Multiple data types per key will throw an exception, for example: {foo: bar} and {foo: 42} is not allowed.

Important

Avoid defining too many user-specified labels. Defining too many unique fields in an index is a condition that can lead to a mapping explosion.

Custom context adds non-indexed, custom contextual information to transactions and errors. Non-indexed means the data is not searchable or aggregatable in Elasticsearch, and you cannot build dashboards on top of the data. This also means you don’t have to worry about mapping explosions, as these fields are not added to the mapping.

Non-indexed information is useful for providing contextual information to help you quickly debug performance issues or errors.

  • Indexed: No
  • Elasticsearch type: object
  • Elasticsearch fields: transaction.custom | error.custom
  • Applies to: Transactions | Errors
Important

Setting a circular object, a large object, or a non JSON serializable object can lead to errors.

User context adds indexed user information to transactions and errors. Indexed means the data is searchable and aggregatable in Elasticsearch.

  • Indexed: Yes
  • Elasticsearch type: keyword
  • Elasticsearch fields: user.email | user.name | user.id
  • Applies to: Transactions | Errors