Skip to content

PLAT-5416: Alert team routing pilot - #6

Closed
houayang wants to merge 3 commits into
masterfrom
PLAT-5416-alert-team-routing
Closed

houayang wants to merge 3 commits into
masterfrom
PLAT-5416-alert-team-routing

Conversation

@houayang

Copy link
Copy Markdown

What

Adds optional CODEOWNERS-based span tagging so decorated traces can carry the owning team.

When :codeowners_path is set on the :spandex :decorators config, Spandex.Decorators (@decorate trace / @decorate span) merge a code_owner tag onto the span. Ownership is resolved from the module's compile source path against a CODEOWNERS file (last matching rule wins, same as git). Explicit :tags at the call site are left alone. With no path configured, behavior is unchanged and no tags are added.

Why

Pilot for PLAT-5416 alert team routing: Datadog spans need a stable team tag so alerts can be routed to the CODEOWNERS team for the code that produced the span, without every call site tagging itself.

Jira ticket

https://carsenterprise.atlassian.net/browse/PLAT-5416

Queries

N/A — no database queries.

Migration Checklist

N/A — no migrations.

Steps to Validate/Verify

  1. In a consumer app (e.g. cars_platform), configure:

    config :spandex, :decorators,
      tracer: MyApp.Tracer,
      codeowners_path: Path.expand(".github/CODEOWNERS")

@houayang houayang closed this Sep 10, 2026
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.

1 participant