Skip to content

Commit

Permalink
Merge pull request #18542 from mangulonr/patch-86
Browse files Browse the repository at this point in the history
Update kubernetes-summary-page.mdx
  • Loading branch information
nbaenam committed Sep 6, 2024
2 parents a46a0e6 + f804b2f commit 8560838
Showing 1 changed file with 36 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,40 @@ The Kubernetes page in APM offers the following information about your applicati

## Link your applications to Kubernetes [#link-app]

You can surface Kubernetes metadata and link it to your APM agents. The `MutatingAdmissionWebhook` is used to add the required environment variables to Pods. APM uses injected environment variables to display the specific Kubernetes deployment information related to that APM application.
You can surface Kubernetes metadata and link it to your APM agents, whether you use NR's proprietary agents or OpenTelemetry. <InlinePopover type="apm"/> uses the Kubernetes metadata to display the specific Kubernetes deployment information related to that APM application.

### New Relic proprietary instrumentation [#nr-proprietary]

When you [install New Relic's Kubernetes integration](/install/kubernetes/), New Relic's metadata injection comes into play automatically via the `nri-metadata-injection` parameter. The `MutatingAdmissionWebhook`, set up by the Kubernetes instrumentation, takes care of tagging your pods with the necessary environment variables. From there, the data captured in these variables gets carried over to your APM metrics and entities, enriching them with valuable context.

For more information, see how to [link your applications to Kubernetes](/docs/kubernetes-pixie/kubernetes-integration/advanced-configuration/link-your-applications-kubernetes/).

The following attributes are required in the APM service entity to display the Kubernetes summary page:

* `k8s.clusterName`
* `k8s.namespaceName`
* `k8s.deploymentName`


### OpenTelemetry instrumentation [#otel-instrumentation]

The [OpenTelemetry collector](/docs/opentelemetry/get-started/collector-processing/opentelemetry-collector-processing-intro/) offers a Kubernetes attributes processor that enrich APM telemetry with Kubernetes metadata.

1. You need to define an environment variable in your deployment manifest.

2. Adjust the configuration of the collector to retrieve the appropriate Kubernetes metadata using this APM environment variable.

As a result, all the APM metrics and entities will include Kubernetes metadata thanks to the K8sattributes processor. For more information, see how to [link your OpenTelemetry applications to Kubernetes](/docs/kubernetes-pixie/kubernetes-integration/advanced-configuration/link-otel-applications-kubernetes/).

The following attributes are required in the APM service entity to display the Kubernetes summary page:

* `k8s.cluster.name`
* `k8s.deployment.name`
* `k8s.namespace.name`

<Callout variant="caution">
The Kubernetes summary page won't work properly if there is a mix of different instrumentation providers (newRelic and OpenTelemetry). For it to work properly, both Kubernetes and APM need to be monitored either exclusively through New Relic's proprietary agents or entirely through OpenTelemetry.

As of now, we don't support hybrid scenarios.
</Callout>

New Relic's metadata injection is automatically added during the installation of New Relic's Kubernetes integration through the `newrelic-metadata-injection` label. For more information, see how to [link your applications to Kubernetes](/docs/kubernetes-pixie/kubernetes-integration/advanced-configuration/link-your-applications-kubernetes/).

0 comments on commit 8560838

Please sign in to comment.