Skip to content

Commit 46ea427

Browse files
authored
explain issue related to L7 load balancers with apm-server (#614)
1 parent 7aab4d9 commit 46ea427

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

solutions/observability/apps/upstream-opentelemetry-collectors-language-sdks.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -257,6 +257,11 @@ If you use the OTLP/gRPC protocol, requests to Elastic must use either HTTP/2 ov
257257

258258
When using a layer 7 (L7) proxy like AWS ALB, requests must be proxied in a way that ensures requests to Elastic follow the rules outlined above. For example, with ALB you can create rules to select an alternative backend protocol based on the headers of requests coming into ALB. In this example, you’d select the gRPC protocol when the `"Content-Type: application/grpc"` header exists on a request.
259259

260+
Many L7 load balancers handle HTTP and gRPC traffic separately and rely on explicitly defined routes and service configurations to correctly proxy requests. Since APM Server serves both protocols on the same port, it may not be compatible with some L7 load balancers. For example, to work around this issue in [Ingress NGINX Controller for Kubernetes](https://github.com/kubernetes/ingress-nginx), either:
261+
262+
* Use the `otlp` exporter in the OTel collector. Set annotation `nginx.ingress.kubernetes.io/backend-protocol: "GRPC"` on the K8s Ingress object proxying to APM Server.
263+
* Use the `otlphttp` exporter in the OTel collector. Set annotation `nginx.ingress.kubernetes.io/backend-protocol: "HTTP"` (or `"HTTPS"` if APM Server expects TLS) on the K8s Ingress object proxying to APM Server.
264+
260265
For more information on how to configure an AWS ALB to support gRPC, see this AWS blog post: [Application Load Balancer Support for End-to-End HTTP/2 and gRPC](https://aws.amazon.com/blogs/aws/new-application-load-balancer-support-for-end-to-end-http-2-and-grpc/).
261266

262267
For more information on how APM Server services gRPC requests, see [Muxing gRPC and HTTP/1.1](https://github.com/elastic/apm-server/blob/main/dev_docs/otel.md#muxing-grpc-and-http11).
@@ -266,4 +271,4 @@ For more information on how APM Server services gRPC requests, see [Muxing gRPC
266271

267272
* [Collect metrics](../../../solutions/observability/apps/collect-metrics.md)
268273
* Add [Resource attributes](../../../solutions/observability/apps/resource-atrributes.md)
269-
* Learn about the [limitations of this integration](../../../solutions/observability/apps/limitations.md)
274+
* Learn about the [limitations of this integration](../../../solutions/observability/apps/limitations.md)

0 commit comments

Comments
 (0)