Skip to content

Commit

Permalink
Apache doc in README
Browse files Browse the repository at this point in the history
  • Loading branch information
chrlic committed Sep 8, 2022
1 parent bd7f1be commit 0555256
Showing 1 changed file with 26 additions and 1 deletion.
27 changes: 26 additions & 1 deletion README.md
Expand Up @@ -166,7 +166,7 @@ When using sidecar mode the OpenTelemetry collector container will have the envi

### OpenTelemetry auto-instrumentation injection

The operator can inject and configure OpenTelemetry auto-instrumentation libraries. Currently DotNet, Java, NodeJS and Python are supported.
The operator can inject and configure OpenTelemetry auto-instrumentation libraries. Currently DotNet, Java, NodeJS, Python and Apache httpd are supported.

To use auto-instrumentation, configure an `Instrumentation` resource with the configuration for the SDK and instrumentation.

Expand Down Expand Up @@ -215,6 +215,11 @@ DotNet:
instrumentation.opentelemetry.io/inject-dotnet: "true"
```

Apache:
```bash
instrumentation.opentelemetry.io/inject-apache: "true"
```

OpenTelemetry SDK environment variables only:
```bash
instrumentation.opentelemetry.io/inject-sdk: "true"
Expand Down Expand Up @@ -286,11 +291,31 @@ spec:
image: your-customized-auto-instrumentation-image:python
dotnet:
image: your-customized-auto-instrumentation-image:dotnet
apache:
image: your-customized-auto-instrumentation-image:apache
```

The Dockerfiles for auto-instrumentation can be found in [autoinstrumentation directory](./autoinstrumentation).
Follow the instructions in the Dockerfiles on how to build a custom container image.

>**Note:** For `Apache` auto-instrumentation, by default, instrumentation assumes httpd version 2.4. If you need to use version 2.2, or you need to adjust agent parameters, adjust instrumentation per following example:
```yaml
apiVersion: opentelemetry.io/v1alpha1
kind: Instrumentation
metadata:
name: my-instrumentation
apache:
image: your-customized-auto-instrumentation-image:apache
version: 2.2
attrs:
- name: ApacheModuleOtelMaxQueueSize
value: "4096"
- name: ...
value: ...
```
List of all attributes can be found at [otel-webserver-module](https://github.com/open-telemetry/opentelemetry-cpp-contrib/tree/main/instrumentation/otel-webserver-module)


#### Inject OpenTelemetry SDK environment variables only

You can configure the OpenTelemetry SDK for applications which can't currently be autoinstrumented by using `inject-sdk` in place of (e.g.) `inject-python` or `inject-java`. This will inject environment variables like `OTEL_RESOURCE_ATTRIBUTES`, `OTEL_TRACES_SAMPLER`, and `OTEL_EXPORTER_OTLP_ENDPOINT`, that you can configure in the `Instrumentation`, but will not actually provide the SDK.
Expand Down

0 comments on commit 0555256

Please sign in to comment.