Task/otel project connection - #38
Open
muzamilkm wants to merge 7 commits into
Open
Conversation
…y status color + missing pure-utility tests
muzamilkm
marked this pull request as ready for review
August 28, 2026 14:59
ubaidkhalidarbisoft
approved these changes
Sep 8, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds DevLake project placement for Claude Code OTel connections so a team credential can be associated with one or more DevLake projects without treating project membership as telemetry attribution.
Project placement is stored as DevLake configuration metadata. The trusted
devlake_teamlabel still comes from the authenticated OTel credential, while project-scoped dashboards resolve the projects linked to those teams through MySQL.Included
_tool_claude_code_otel_connection_projectsand migration support for many-to-many OTel connection/project placement.devlake_team, while MySQL maps the selected DevLake project to its linked teams.devlake_projectattribute in the Collector. Project placement is not repository-level attribution and is never trusted from telemetry.Project Lifecycle Boundary
The normal Config UI delete flow performs OTel preflight and placement cleanup before deleting a project.
A direct client of the generic
DELETE /projects/:projectNameAPI can still bypass this plugin-owned lifecycle because upstream DevLake currently exposes no project-deletion extension hook. This can leave stale OTel placement metadata after direct API deletion.Fixing that cleanly requires an upstream/core project lifecycle hook and is intentionally left outside this PR to avoid coupling the OTel feature directly into core deletion logic. Issue created: apache#9081
Scope and Upstream Coupling
Most backend changes remain isolated in
backend/plugins/claude_otel, with Config UI integration limited to the existing OTel screens and project detail/delete flows.The Grafana change only adds project/team filtering to the Claude dashboard. Metric attribution continues to use the trusted credential-derived
devlake_teamlabel rather than introducing a project label into telemetry.Verification
This PR includes focused coverage for:
Additional staging validation will cover creating shared-team placements, project-scoped dashboard filtering, moving a connection between projects, and project deletion behavior.
Deferred