Add Tagged Activity template for trace-tag attribution - #3
Closed
kmccarp wants to merge 1 commit into
Closed
Conversation
Adds a template that groups committed output by a trace tag (example: tag.changeSetId), reporting commits, repos changed, distinct recipes, and hours saved per tag value, with a per-commitId dedup so push re-emission does not inflate totals. Documents the --trace-tag feature and the tag.<key> columns in the data dictionary and links the template from the top-level README.
Contributor
|
Moved to docs and |
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.
Background / problem
Every command that emits a trace accepts a repeatable
--trace-tag key=valueoption, which appends atag.<key>column to the trace.csv so telemetry can be attributed to a dimension the trace does not otherwise capture — a change set, a team, a region, a ticket. None of the existing templates use these columns, and the data dictionary does not document them, so the capability is effectively invisible to anyone building reports from the trace data.Solution
Adds a Tagged Activity template that groups committed output by a trace tag and reports successful commits, repos changed, distinct recipes, and estimated hours saved per tag value. The example groups by
tag.changeSetId— the canonical tag for correlating a change set's runs and commits — but anytag.<key>column works. Like the other commit-based templates, the query collapses to one row percommitIdbefore aggregating so push re-emission does not inflate the totals.The change also documents the
--trace-tagfeature and thetag.<key>columns in the data dictionary, including the dot-quoting caveat for SQL identifiers, and links the new template from the top-level README. The template ships with the usual SQL, README, notebook, sample data, and rendered chart.Test plan
tagged-activity.ipynbagainst the bundled sample data and confirm the chart renders.tagged-activity.sqlagainst a trace table containing tagged runs and confirm the per-tag attribution.