Skip to content

Conversation

@kellrott
Copy link
Contributor

No description provided.

…lso reverting the logging to fix debug output issue
@bwalsh
Copy link
Contributor

bwalsh commented Jan 13, 2026

Summary

Token refresh now triggers a new token request when the access token is expired or when the expiration claim can’t be parsed, ensuring tokens are refreshed even on parsing errors.

Logging was simplified to use the standard library *log.Logger, removing the custom thread-safe wrapper and providing a global logger plus a no-op logger for tests/fallbacks.

Logger usage across DRS components was updated to accept *log.Logger (e.g., remote client wiring and DRS map operations), and indexd page parsing now logs the response body alongside unmarshal errors for better diagnostics.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR simplifies the logging infrastructure by replacing the custom drslog.Logger wrapper with Go's standard log.Logger. The custom wrapper previously added thread-safety with mutex locks, but this is unnecessary since log.Logger is already thread-safe.

Changes:

  • Removed custom drslog.Logger type and its mutex-based thread-safety wrappers
  • Updated all function signatures across the codebase to use *log.Logger instead of *drslog.Logger
  • Improved test reliability by using NewNoOpLogger() instead of GetLogger() in tests
  • Enhanced error logging in ListObjects to include response body for debugging

Reviewed changes

Copilot reviewed 15 out of 15 changed files in this pull request and generated 6 comments.

Show a summary per file
File Description
drslog/logger.go Simplified logger by removing custom wrapper and mutex-based thread-safety
s3_utils/s3.go Updated type signatures to use standard log.Logger
drsmap/drs_map.go Updated function signatures to use standard log.Logger
drs/store.go Updated function signatures to use standard log.Logger
config/config.go Updated interface and method signatures to use standard log.Logger
cmd/remote/add/gen3.go Updated function signature to use standard log.Logger
cmd/remote/add/anvil.go Updated function signature to use standard log.Logger
cmd/initialize/main.go Updated function signature to use standard log.Logger
client/indexd/tests/test_helpers_test.go Improved test isolation by using NewNoOpLogger()
client/indexd/tests/client_read_test.go Improved test isolation by using NewNoOpLogger()
client/indexd/indexd_client.go Enhanced error message and updated type signature
client/indexd/gen3_remote.go Updated method signature to use standard log.Logger
client/indexd/auth_handler.go Modified token refresh logic and has spelling error
client/indexd/add_url.go Updated function signatures to use standard log.Logger
client/anvil/remote.go Updated method signature to use standard log.Logger

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@bwalsh bwalsh changed the base branch from main to feature/improve-on-push-filter January 13, 2026 23:20
@bwalsh bwalsh merged commit 4a33c47 into feature/improve-on-push-filter Jan 14, 2026
1 check passed
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