Skip to content

Commit 64b44b9

Browse files
updates
1 parent b04890c commit 64b44b9

File tree

1 file changed

+30
-31
lines changed

1 file changed

+30
-31
lines changed

articles/container-apps/opentelemetry-agents.md

Lines changed: 30 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ description: Learn to record and query data collected using OpenTelemetry in Azu
44
services: container-apps
55
author: craigshoemaker
66
ms.service: container-apps
7-
ms.date: 03/07/2024
7+
ms.date: 03/08/2024
88
ms.author: cshoe
99
---
1010

@@ -29,9 +29,9 @@ Through simple configuration settings, the Container Apps OTel agent makes it ea
2929
- Send data to one or multiple destinations
3030
- Switch collection destinations
3131

32-
This article shows you how to setup and configure an OTel agent for your container app.
32+
This article shows you how to set up and configure an OTel agent for your container app.
3333

34-
## Set up a agent
34+
## Set up an agent
3535

3636
Setting up an agent is a two step process. The first step is to create an instance of the destination service to accept data from your container app. For instance, if you want to send data to Azure Application Insights, you first need to create an App Insights instance.
3737

@@ -106,7 +106,7 @@ Once you have these configuration details, you can configure the agent via your
106106

107107
---
108108

109-
## OLTP endpoint
109+
## OTLP endpoint
110110

111111
An OpenTelemetry protocol (OTLP) endpoint is a telemetry data destination that consumes OpenTelemery data. You can use existing solutions that support OTLP, or develop your own according to the OpenTelemetry protocol.
112112

@@ -135,22 +135,27 @@ While you can set up as many OTLP-configured endpoints as you like, each endpoin
135135

136136
| Name | Description |
137137
|---|---|
138-
| `name` | The name of your OTLP-configured endpoint |
139-
| `endpoint` | The URL to receive the data |
140-
| `header` | List of any headers used for security |
138+
| `name` | A name you select to identify your OTLP-configured endpoint. |
139+
| `endpoint` | The URL of the destination that receives collected data. |
140+
| `header` | List of security headers. |
141141
| `insecure` | True/false. If false, include headers to |
142142

143143
# [Azure CLI](#tab/azure-cli)
144144

145145
```azurecli
146146
az containerapp env telemetry otlp add \
147147
--name <ENDPOINT_NAME> \
148-
--endpoint <ENDPOINT_URI> \
149-
--insecure <TRUE/FALSE>
148+
--endpoint <ENDPOINT_URL> \
149+
--insecure <IS_INSECURE>
150150
--headers <HEADERS>
151151
```
152152

153-
TODO
153+
| Name | Description |
154+
|---|---|
155+
| `<ENDPOINT_NAME>` | A name you select to identify your OTLP-configured endpoint. |
156+
| `<ENDPOINT_URL>` | The URL of the destination that receives collected data. |
157+
| `<IS_INSECURE>` | True/false. If false, include headers to |
158+
| `<HEADERS>` | List of security headers. |
154159

155160
---
156161

@@ -169,9 +174,9 @@ The OTel agent divides data up into the following categories:
169174
- Metrics
170175
- Logs
171176

172-
You can send each type of data to different locations, but you can also choose not to send one of the data categories a agent.
177+
You can send each type of data to different locations, but you can also choose not to send one of the data categories an agent.
173178

174-
To configure a agent, use the `destinations` array to define which agents your application sends data. Valid keys are either `appInsights`, `dataDog`, or the name of your custom OTLP endpoint.
179+
To configure an agent, use the `destinations` array to define which agents your application sends data. Valid keys are either `appInsights`, `dataDog`, or the name of your custom OTLP endpoint.
175180

176181
The following example shows how to use an OTLP endpoint named `customDashboard`.
177182

@@ -209,7 +214,6 @@ The following example shows how to use an OTLP endpoint named `customDashboard`.
209214

210215
The following example show how you might configure your container app to collect telemetry data using Azure Application Insights, Datadog, and with a custom OTLP agent named `customDashboard`.
211216

212-
213217
# [ARM template](#tab/arm)
214218

215219
```json
@@ -229,7 +233,7 @@ The following example show how you might configure your container app to collect
229233
"otlpConfigurations": [
230234
{
231235
"name": "customDashboard",
232-
"endpoint": "<OLTP_ENDPOINT_URI>",
236+
"endpoint": "<OTLP_ENDPOINT_URI>",
233237
"insecure": true
234238
}
235239
]
@@ -259,40 +263,35 @@ The following example show how you might configure your container app to collect
259263

260264
# [CLI](#tab/cli)
261265

262-
Use a combination of commands with `az containerapp env telemetry` that match the type of agent you want to enable.
266+
Use a combination of commands with `az containerapp env telemetry` that match the type of agent you want to enable. The following table lists the agents you can enable.
263267

264268
| Command | Description |
265269
|---|---|
266270
| `app-insights` | Application Insights agent |
267271
| `data-dog` | Datadog agent |
268272
| `otlp` | Custom OTLP agent |
269273

274+
Once you select an agent, then you can enable the type of data you want to collect. The following table lists the parameters available to enable or disable different categories of data to collect.
270275

276+
| Parameter | Value |
277+
|---|---|
278+
| `--enable-open-telemetry-traces` | `true` or `false` |
279+
| `--enable-open-telemetry-logs` | `true` or `false` |
280+
| `--enable-open-telemetry-metrics` | `true` or `false` |
271281

272-
| Parameter | Value | Description |
273-
|---|---|---|
274-
| `--enable-open-telemetry-traces` | `true` or `false` | |
275-
| `--enable-open-telemetry-logs` | `true` or `false` | |
276-
| `--enable-open-telemetry-metrics` | `true` or `false` | |
282+
For example, if you wanted to start collecting traces and logs with Application Insights you would use the following command.
277283

284+
```azurecli
278285
az containerapp env telemetry app-insights set
279286
  --enable-open-telemetry-traces true
280287
  --enable-open-telemetry-logs true
281-
282-
az containerapp env telemetry data-dog set
283-
  --enable-open-telemetry-traces true
284-
  --enable-open-telemetry-metrics true
285-
286-
az containerapp env telemetry otlp update
287-
  --enable-open-telemetry-traces true
288-
  --enable-open-telemetry-logs true
289-
  --enable-open-telemetry-metrics true
288+
```
290289

291290
---
292291

293292
## Send data from your app to an OTel agent
294293

295-
For data to be sent to the agent, install the OSS OTEL SDK (link) to your code. The otel agent auto injects environment variables during app runtime to pick up any logs, metrics, or traces produced using the SDK. See example for details.
294+
To send data to an agent, install the [OTel SDK](https://opentelemetry.io/ecosystem/integrations/) into your application. The OTel agent automatically injects environment variables when your application runs to pick up logs, metrics, or traces produced while using the SDK.
296295

297296
## OTel agent costs
298297

@@ -306,7 +305,7 @@ For example, if you send data to both Azure App Insights and Datadog, you're res
306305

307306
### How can I use an OTLP agent with a Dapr Sidecar?
308307

309-
You can configure Dapr to send traces to App Insights without a agent, but you can choose to use an OTel agent as an alternative.
308+
You can configure Dapr to send traces to App Insights without an agent, but you can choose to use an OTel agent as an alternative.
310309

311310
By default an OTel agent doesn't include system data, but you can include system level messages (including Dapr telemetry) by setting `includeSystemTelemetry` to `true`.
312311

0 commit comments

Comments
 (0)