Migrate GitLab Shell to slog

Summary

Migrate GitLab Shell to use Go's standard slog package for structured logging.

Why GitLab Shell?

GitLab Shell handles SSH access for GitLab and is a critical component for Git operations over SSH. Standardizing its logging will improve observability and consistency.

Goals

  • Replace current logging implementation with slog
  • Maintain backward compatibility with existing log formats where possible
  • Ensure no performance regressions
  • Validate that slog meets GitLab Shell's requirements
  • Align with standardized logging patterns

Migration Checklist

  • Audit current logging implementation
  • Design slog handler configuration for GitLab Shell
  • Implement slog integration
  • Update all log call sites
  • Update tests to work with new logging setup
  • Benchmark performance (before/after comparison)
  • Update documentation
  • Deploy to staging environment
  • Monitor for issues
  • Deploy to production
  • Document lessons learned

Success Criteria

  • All logging uses slog
  • No performance regressions observed
  • Log format remains compatible with existing log consumers
  • Tests pass
  • Documentation updated

Related