Skip to content

chore: migrate log.Printf to log/slog in llmpool, llmrec, intercept and db - #523

Merged
BaaRai merged 1 commit into
BaaRai:mainfrom
rahulremany:chore/slog-llmpool-llmrec-intercept-db
Nov 26, 2026
Merged

BaaRai merged 1 commit into
BaaRai:mainfrom
rahulremany:chore/slog-llmpool-llmrec-intercept-db

Conversation

@rahulremany

Copy link
Copy Markdown
Contributor

Summary

Follow-up to #488. This moves the remaining log.Printf calls in llmpool, llmrec, intercept and db (18 calls, 8 files) to log/slog. Messages keep their [tag] prefix, the format arguments become structured attributes, and levels are Warn for failover and breaker events and Error for failed writes and dropped outbox entries. server, agent and cmd/artex are left for separate PRs to keep review small.

Test plan

  • gofmt -l, go build ./... and go vet are clean.
  • go test -p 1 ./llmpool ./llmrec ./intercept ./db passes against Postgres 16.
  • intercept/store_error_test.go, which checks the captured log output, still passes.

…nd db

Follow-up to BaaRai#488. Replaces the remaining 18 log.Printf calls in these four
packages with structured slog calls, keeping the [tag] prefix that the log
sink uses. Format arguments become key/value attributes.
@5P34R

5P34R commented Nov 26, 2026

Copy link
Copy Markdown
Contributor

Review notes

Looks good to merge. The fields are the same as before, so no secrets are newly logged, and Fatal/exit behaviour is unchanged. maskURLCredentials still masks user:pass@ in quoted slog values. It touches different files from #533 and #536.

@BaaRai
BaaRai merged commit 0768c50 into BaaRai:main Nov 26, 2026
7 checks passed
@BaaRai

BaaRai commented Nov 26, 2026

Copy link
Copy Markdown
Owner

Merged, thanks @rahulremany. Verified on current main with its tests and negative control.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants