From f91c98e2f4bdda74a5bf6fe405c831c0d09ae538 Mon Sep 17 00:00:00 2001 From: jerevoss Date: Wed, 24 May 2023 15:11:35 -0700 Subject: [PATCH 1/2] distro selection docs --- .../en/docs/instrumentation/python/automatic/_index.md | 4 ++++ .../docs/instrumentation/python/automatic/agent-config.md | 8 ++++++++ 2 files changed, 12 insertions(+) diff --git a/content/en/docs/instrumentation/python/automatic/_index.md b/content/en/docs/instrumentation/python/automatic/_index.md index d070b44e3b22..8370fe896513 100644 --- a/content/en/docs/instrumentation/python/automatic/_index.md +++ b/content/en/docs/instrumentation/python/automatic/_index.md @@ -48,6 +48,8 @@ opentelemetry-instrument \ --metrics_exporter console \ --service_name your-service-name \ --exporter_otlp_endpoint 0.0.0.0:4317 \ + --distro distro + --configurator configurator python myapp.py ``` @@ -58,6 +60,8 @@ OTEL_SERVICE_NAME=your-service-name \ OTEL_TRACES_EXPORTER=console,otlp \ OTEL_METRICS_EXPORTER=console \ OTEL_EXPORTER_OTLP_TRACES_ENDPOINT=0.0.0.0:4317 +OTEL_PYTHON_DISTRO=distro +OTEL_PYTHON_CONFIGURATOR=configurator opentelemetry-instrument \ python myapp.py ``` diff --git a/content/en/docs/instrumentation/python/automatic/agent-config.md b/content/en/docs/instrumentation/python/automatic/agent-config.md index c67ae08919a5..22b523603409 100644 --- a/content/en/docs/instrumentation/python/automatic/agent-config.md +++ b/content/en/docs/instrumentation/python/automatic/agent-config.md @@ -17,6 +17,8 @@ Here's an example of agent configuration via configuration properties: ```sh opentelemetry-instrument \ + --distro distro \ + --configurator configurator \ --traces_exporter console,otlp \ --metrics_exporter console \ --service_name your-service-name \ @@ -26,6 +28,8 @@ opentelemetry-instrument \ Here's an explanation of what each configuration does: +- `distro` specifies which distro should be loaded. Argument should be the entry point name of the desired distro. If only a single distro exists, this argument may be left out. +- `configurator` specifies which configurator should be loaded. Argument should be the entry point name of the desired configurator. If only a single configurator exists, this argument may be left out. - `traces_exporter` specifies which traces exporter to use. In this case, traces are being exported to `console` (stdout) and with `otlp`. The `otlp` option tells `opentelemetry-instrument` to send the traces to an endpoint that @@ -67,6 +71,10 @@ For example, `exporter_otlp_endpoint` would convert to There are some python specific configuration options you can set by prefixing environment variables with `OTEL_PYTHON_`. +### Selecting Distro and Configurator + +In addition to the `distro` and `configurator` arguments, you can use the `OTEL_PYTHON_DISTRO` and `OTEL_PYTHON_CONFIGURATOR` environment variables. If only a single distro or configurator exists, these arguments may be left out. + ### Excluded URLs Comma-separated regexes representing which URLs to exclude across all From e8777b5c1d33f47eefc33b8e9b96d84b872be319 Mon Sep 17 00:00:00 2001 From: jerevoss Date: Wed, 24 May 2023 16:30:26 -0700 Subject: [PATCH 2/2] lint --- .../instrumentation/python/automatic/agent-config.md | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/content/en/docs/instrumentation/python/automatic/agent-config.md b/content/en/docs/instrumentation/python/automatic/agent-config.md index 22b523603409..618d0b5c6ce7 100644 --- a/content/en/docs/instrumentation/python/automatic/agent-config.md +++ b/content/en/docs/instrumentation/python/automatic/agent-config.md @@ -28,8 +28,12 @@ opentelemetry-instrument \ Here's an explanation of what each configuration does: -- `distro` specifies which distro should be loaded. Argument should be the entry point name of the desired distro. If only a single distro exists, this argument may be left out. -- `configurator` specifies which configurator should be loaded. Argument should be the entry point name of the desired configurator. If only a single configurator exists, this argument may be left out. +- `distro` specifies which distro should be loaded. Argument should be the entry + point name of the desired distro. If only a single distro exists, this + argument may be left out. +- `configurator` specifies which configurator should be loaded. Argument should + be the entry point name of the desired configurator. If only a single + configurator exists, this argument may be left out. - `traces_exporter` specifies which traces exporter to use. In this case, traces are being exported to `console` (stdout) and with `otlp`. The `otlp` option tells `opentelemetry-instrument` to send the traces to an endpoint that @@ -73,7 +77,9 @@ environment variables with `OTEL_PYTHON_`. ### Selecting Distro and Configurator -In addition to the `distro` and `configurator` arguments, you can use the `OTEL_PYTHON_DISTRO` and `OTEL_PYTHON_CONFIGURATOR` environment variables. If only a single distro or configurator exists, these arguments may be left out. +In addition to the `distro` and `configurator` arguments, you can use the +`OTEL_PYTHON_DISTRO` and `OTEL_PYTHON_CONFIGURATOR` environment variables. If +only a single distro or configurator exists, these arguments may be left out. ### Excluded URLs