Skip to content

fix: classify ALB events as load_balancer, not API Gateway#63

Merged
GuyMoses merged 2 commits into
masterfrom
fix/alb-trigger-misclassified-as-apigw
Jun 8, 2026
Merged

fix: classify ALB events as load_balancer, not API Gateway#63
GuyMoses merged 2 commits into
masterfrom
fix/alb-trigger-misclassified-as-apigw

Conversation

@GuyMoses

@GuyMoses GuyMoses commented Jun 3, 2026

Copy link
Copy Markdown
Contributor

ALB target-group events carry requestContext.elb. The dispatcher classified anything with requestContext as API Gateway, so ALB-triggered Lambdas were emitted as an aws:api_gateway trigger-chain hop.

Fix: detect requestContext.elb before the API Gateway branch and emit an aws:load_balancer hop with the target group ARN + name (parsed as the segment after targetgroup/, since the generic ARN parser would return the trailing id).

Mirrors the same fix on the other ingestion path (tracing-ingestion #2156) so both agree on the aws:load_balancer chain type; the FE renders it via dash0 #13367.

Tests: ALB → aws:load_balancer hop with target-group name/ARN; not misclassified as API Gateway; missing targetGroupArn still yields a load_balancer hop. cargo test trigger_chain 46 pass, cargo fmt --check clean.

ALB target-group events carry requestContext.elb. The dispatcher keyed off
requestContext alone, so ALB-triggered Lambdas were emitted as an
aws:api_gateway trigger-chain hop. Detect requestContext.elb first and emit an
aws:load_balancer hop carrying the target group ARN and name.

Mirrors the same fix in tracing-ingestion's trigger_chain.py so both ingestion
paths agree on the aws:load_balancer chain type.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@GuyMoses GuyMoses merged commit 622fcb1 into master Jun 8, 2026
146 of 156 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants