logstash

package module
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 25, 2026 License: MIT Imports: 7 Imported by: 0

README

togo

togo-framework/log-logstash

marketplace pkg.go.dev MIT

Part of the togo framework.

Install

togo install togo-framework/log-logstash

togo

log-logstash

part of the togo-framework — the full-stack Go + React framework

Logstash log shipping for togo. Streams your app's slog logs as JSON lines to a Logstash TCP input (e.g. into the ELK stack), in addition to the existing local/stdout output.

togo install togo-framework/log-logstash

Install alongside togo-framework/log. Blank-importing the plugin registers it.

Env

Var Required Description
LOGSTASH_ADDR yes host:port of a tcp { codec => json_lines } input. No-op when empty.

Example Logstash input:

input { tcp { port => 5000 codec => json_lines } }

How it works

On boot (after the log plugin) it wraps the kernel logger so every record is also written as a JSON line over a reconnecting TCP connection to Logstash. Connection failures are swallowed so logging never breaks the app.

MIT © togo-framework


Premium sponsors

ID8 Media  ·  One Studio

Support togo — become a sponsor.

Documentation

Overview

Package logstash ships togo's slog logs as JSON lines to a Logstash TCP input, in addition to the app's existing log output. Install alongside togo-framework/log; blank-import registers it.

Env: LOGSTASH_ADDR (host:port of a `tcp { codec => json_lines }` input — required, no-op when empty).

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL