debugging-runtime-logs
Skill2 starsChanged 44 days agoMITView on GitHub
Use when debugging a runtime failure in a locally-running fleet of Spring Boot microservices - correlates logs across services by a trace key, reconstructs the cross-service timeline, isolates the failing hop, and maps it back to source.
In this repository10 other files it gives its agents.
- debugSkill
- doctorSkill
- federating-mcp-serversSkill
- fleet-initSkill
- impactSkill
- logsSkill
- runSkill
- spring-fleet-logging-setupSkill
- traceSkill
- tracing-across-servicesSkill
The file
We split this skill into the rules it gives an agent
4 rules. About 0 are common, 3 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈3
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 8
When something breaks in a multi-service dev run, the symptom usually appears in one service while the cause lives in another.
- Distinctive: line 30
Run directly if you prefer:
- Distinctive: line 36
Read the timeline as a story: Follow the request hop by hop.
- Very specific: line 64
No plugin subagents (Codex): read agents/log-correlator.md and agents/fleet-explorer.md under the plugin root and do that work yourself.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Debugging Runtime Logs Across a Service Fleet
When something breaks in a multi-service dev run, the symptom usually appears in one service while the cause lives in another. This skill correlates logs across the whole fleet and ties the failure back to code.
Prerequisites
- A
spring-fleet.config.jsonexists (else run/fleet-init). - Services write to the configured
logDir(see thespring-fleet-logging-setupskill if logs are scattered or console-only).
Procedure
- Get a correlation handle. Best case: an OTel
trace_id(32-char hex) from the user's APM dashboard or atraceparentheader, or a legacysessionId/X-Request-Idfrom a failed request. Otherwise, start from the error message/stack the user pasted; extract a key from a nearby log line, preferringtrace_idoversessionId. Dispatch the
log-correlatoragent with the config path and the trace value (or error snippet). It runsscripts/correlate_logs.pyand returns one chronological cross-service timeline plus a failure-origin analysis.Run directly if you prefer:
python "${CLAUDE_PLUGIN_ROOT}/scripts/correlate_logs.py" \ --config ./spring-fleet.config.json --value <traceValue>- Read the timeline as a story. Follow the request hop by hop. The first ERROR/exception in time order is the likely origin; everything after it is usually propagation. Watch the time gaps: a long gap before an error often means a timeout.
- Map the origin to code. Take the failing service + class from the log and
open the source. For a cross-service cause, dispatch the
fleet-exploreragent (or use thetracing-across-servicesskill) to confirm the call path. - Report. State: what the user did, the cross-service timeline, the failure
origin (service +
file:line), how it surfaced upstream, and a ROOT-CAUSE HYPOTHESIS block: what the fault is, where in code to fix it, why the timeline supports that, your confidence, and a concrete suggested fix (snippet or behavior). Always include alternatives the evidence does not rule out. Call out any service with no log file; a missing log can hide the real cause.
Fallbacks
- No trace key in logs: correlate by timestamp window + endpoint and say so.
- Console-only logs: point the user at
spring-fleet-logging-setupto get stable per-service log files (or, later, the/runtee command). - Empty result: the value may be wrong, or the request never reached the
fleet. Widen with
/logs --greparound the timeframe.
Outside Claude Code
${CLAUDE_PLUGIN_ROOT}is the spring-fleet plugin root. Claude Code fills it in; in Codex it is the folder two directories above this SKILL.md.- No plugin subagents (Codex): read
agents/log-correlator.mdandagents/fleet-explorer.mdunder the plugin root and do that work yourself. - spring-fleet MCP tools: pass
config_path(absolute path of the project'sspring-fleet.config.json). Codex starts the server outside the project, so it cannot find the config on its own.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

