slash-init opened a new pull request, #3379:
URL: https://github.com/apache/iggy/pull/3379

   ## Which issue does this PR address?
   
   Closes #3364 
   
   
   ## Rationale
   
   The SDK currently logs to stdout using `log.Printf` and users have no way to 
control 
   it. They can't turn it off, change the log level, or redirect it. This PR 
adds a 
   configurable logger so users can decide whether to enable logging, what 
level of 
   detail they want, and where the logs should go.
   
   
   ## What changed?
   
   The SDK was printing log messages directly to stdout with no user control.
   
   This PR adds a Logger interface that users can pass to the client via 
`WithLogger()`. 
   By default, logging is silent (zero overhead). When enabled, users can 
choose their 
   log level (Debug, Info, Warn, Error) and output destination (stderr, file, 
custom). 
   All internal `log.Printf` calls have been replaced with logger method calls.
   
   
   ## Local Execution
   
   Passed
   
   - Ran `go vet ./...` - no issues
   - Ran `gofmt` - all files formatted correctly
   - Ran `golangci-lint` - no errors or warnings
   - Ran `go build ./...` - builds successfully
   - Ran `go test ./contracts ./client/tcp ./internal/util` - all tests pass
   
   ## AI Usage
   
   Tool: Claude Sonnet 4.6
   
   Scope: Generated the logger interface, DefaultLogger and NoopLogger 
implementations. All generated code was reviewed, integrated and tested 
manually.
   
   Verification: All code compiles and tests pass locally. 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to