@@ -72,6 +72,7 @@ Each option has its own detailed reference in a separate section.
72
72
| [ TLS auth] ( #tls-auth ) | A list of TLS client certificate configuration objects |
73
73
| [ TLS cipher suites] ( #tls-cipher-suites ) | A list of cipher suites allowed to be used by in SSL/TLS interactions with a server |
74
74
| [ TLS version] ( #tls-version ) | String or object representing the only SSL/TLS version allowed |
75
+ | [ Traces output] ( #traces-output ) | Configuration about where traces from k6 should be sent |
75
76
| [ User agent] ( #user-agent ) | A string specifying the User-Agent header when sending HTTP requests |
76
77
| [ Verbose] ( #verbose ) | A boolean specifying whether verbose logging is enabled |
77
78
| [ VUs] ( #vus ) | A number specifying the number of VUs to run concurrently |
@@ -1433,6 +1434,48 @@ export const options = {
1433
1434
1434
1435
{{< /code >}}
1435
1436
1437
+ ## Traces output
1438
+
1439
+ This option specifies where to send traces to. Available in the ` k6 run ` command.
1440
+
1441
+ | Env | CLI | Code / Config file | Default |
1442
+ | ------------------ | ----------------- | ------------------ | ------- |
1443
+ | ` K6_TRACES_OUTPUT ` | ` --traces-output ` | N/A | ` none ` |
1444
+
1445
+ {{< code >}}
1446
+
1447
+ ``` bash
1448
+ $ k6 run --traces-output=otel script.js
1449
+ ```
1450
+
1451
+ {{< /code >}}
1452
+
1453
+ Possible values are:
1454
+
1455
+ - none - disable
1456
+ - otel - send traces to an OTEL compatible backend
1457
+
1458
+ ### OTEL
1459
+
1460
+ Use the ` traces-output ` option to configure [ Open Telemetry] ( https://opentelemetry.io/ ) compatible output as follows.
1461
+
1462
+ {{< code >}}
1463
+
1464
+ ``` bash
1465
+ $ k6 run --traces-output=otel=http://127.0.0.1:4318,proto=http,header.AdditionalHeader=example script.js
1466
+ ```
1467
+
1468
+ {{< /code >}}
1469
+
1470
+ Where none of the options are required.
1471
+ The possible keys with their meanings and default values:
1472
+
1473
+ | key | description | default value |
1474
+ | ------------------- | ---------------------------------------------------------------------------------------------------------------------- | ----------------------- |
1475
+ | ` nothing ` | the endpoint to which send traces to | ` http://127.0.0.1:4317 ` |
1476
+ | proto | the protocol to use when connecting with the traces backend | ` grpc ` |
1477
+ | header.` headerName ` | adds an additional HTTP header with the provided header name and value to each HTTP request made to the traces backend | N/A |
1478
+
1436
1479
## Upload Only
1437
1480
1438
1481
A boolean specifying whether the test should just be uploaded to the cloud, but not run it. Available in ` k6 cloud ` command.
0 commit comments