Repository navigation
[log] Add debug logging to proxy/response_headers.go - #16965
Conversation
Co-authored-by: Copilot <[email protected]>
There was a problem hiding this comment.
🟢 Approval recommended
No active review issues are identified, and the changes are limited to debug logging without altering request or response behavior.
No open issues 🎉
What changed in this PR
Adds debug-level observability to proxy response-header and artifact-download handling using the existing proxy:handler logger, without changing request or response behavior.
Changes:
- Logs streamed artifact-download detection.
- Logs client API URL resolution and
/ghprefix handling. - Logs Link header sizes and rate-limit
Retry-Afterhandling.
| File | Description |
|---|---|
| internal/proxy/response_headers.go | Adds debug logging for artifact detection, client URL resolution, Link header rewriting, and rate-limit handling. |
Review effort: Lite (adaptive)
🔒 mcpg Read-Only Stress — defaultSurface coverage: MCP tool calls + proxied CLI (REST) + GraphQL mutations
Overall: INCONCLUSIVE
No write succeeded on any surface; no artifacts were leaked.
|
Adds 5 debug log calls to
internal/proxy/response_headers.go, reusing the existinglogHandler(proxy:handler):isArtifactDownload: logs when a streamed artifact download is detectedclientAPIURL: logs the resolved client API base and/ghprefix handlingrewriteLinkHeader: logs the Link header size before rewritinginjectRetryAfterIfRateLimited: logs the no-signal path and Retry-After injectionLog arguments are plain values with no side effects.
Validation:
go vet ./internal/proxy,go test ./internal/proxy, andgo build -o awmgall pass.