Skip to content

feat: support multi-instance tool metric source prefixing#109

Closed
k-rister wants to merge 1 commit into
mainfrom
multi-instance-tool-metrics
Closed

feat: support multi-instance tool metric source prefixing#109
k-rister wants to merge 1 commit into
mainfrom
multi-instance-tool-metrics

Conversation

@k-rister
Copy link
Copy Markdown
Contributor

Summary

  • When RICKSHAW_TOOL_ID is set in the environment, log_sample prefixes both the file_id and the metric source descriptor with the tool ID (e.g., sysstat-1sec::mpstat)
  • Ensures CDM keeps metrics from different instances of the same tool separated for correct aggregation
  • No-op when the env var is not set (backwards compatible with single-instance tools)
  • Companion to the rickshaw multi-instance tool support PR which sets RICKSHAW_TOOL_ID during post-processing

Test plan

  • Run with single-instance tools (no RICKSHAW_TOOL_ID set) — verify identical behavior
  • Run with RICKSHAW_TOOL_ID=sysstat-1sec set — verify metric files and sources are prefixed with sysstat-1sec::
  • Verify no double-prefixing when log_sample is called multiple times with the same desc hash

🤖 Generated with Claude Code

When RICKSHAW_TOOL_ID is set in the environment, log_sample prefixes
both the file_id and the metric source with the tool ID (e.g.,
sysstat-1sec::mpstat). This ensures CDM keeps metrics from different
instances of the same tool separated for aggregation.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@k-rister k-rister self-assigned this Apr 21, 2026
@k-rister k-rister requested a review from a team April 21, 2026 14:17
@project-crucible-tracking project-crucible-tracking Bot moved this to In Progress in Crucible Tracking Apr 21, 2026
@k-rister k-rister marked this pull request as draft April 22, 2026 01:30
@k-rister k-rister marked this pull request as draft April 22, 2026 01:30
@k-rister
Copy link
Copy Markdown
Contributor Author

The concept this is used to implement is under review.

@k-rister
Copy link
Copy Markdown
Contributor Author

No longer needed — the existing tool-name field in rickshaw-index already picks up the tool ID from the data directory name, providing the breakout dimension without any toolbox changes.

@k-rister k-rister closed this Apr 22, 2026
@github-project-automation github-project-automation Bot moved this from In Progress to Done in Crucible Tracking Apr 22, 2026
@k-rister k-rister deleted the multi-instance-tool-metrics branch April 22, 2026 15:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

1 participant