2 comments (2 comments)1 reaction (1 reaction)0 assignees (0 assignees)Go25,788 stars (25,788 stars)2,898 forks (2,898 forks)batch import
featurehelp wanted
Description
This can help distinguish log levels in gcp stackdriver 👍
Contributor guide
- Tech stack
- go
- Domain
- backendobservability
- Issue type
- feature
- DifficultyEstimated implementation difficulty for a new contributor, from 1 for very small changes to 5 for expert-level work.
- 2
- Estimated timeA rough time range for an experienced contributor to investigate, implement, test, and prepare a pull request.
- 1-3 hours
- Activity statusHow available the issue appears right now: fresh, active, stale, blocked, or waiting on maintainer input.
- stale
- ClarityHow clearly the issue explains the expected change, acceptance criteria, and next step.
- clear
- Prerequisites
- Go programminglogging concepts
- Newbie friendlinessA 1-100 score estimating how approachable this issue is for first-time contributors.
- 75
- Research direction
- First, examine the current logging setup in the repository (likely in nsqd/logger.go or similar). Identify where log output is written and how log levels are handled. Then, add a new configuration option (e.g., 'log format') that defaults to plain text but accepts 'json'. Implement JSON formatting using Go's encoding/json, ensuring log levels and messages are structured. Test the change locally and verify it works with Stackdriver by checking that the JSON format includes severity. Finally, update documentation and any relevant configuration files.