Orso Labs

Filtering for "go"

Remove filter
Default values in JSON with Golang
How to handle JSON fields with a default value different from the Go zero value (example: a bool with default value true), avoiding the inconveniences of pointers.
Handling errors only once and logging them with full context in Golang
Handling error only once means that we log them at the place of handling, not at the place of occurrence. But how do we do this while providing to the structured log the full context of key/value pairs that is available only at the place of occurrence?