ln: within.website/ln/ex Index | Files

package ex

import "within.website/ln/ex"

Package ex is a set of extensions and middleware for ln.

This package will (inevitably) have a lot of third-party dependencies and as such might be broken apart into other packages in the future.

Index

Package Files

doc.go gotrace.go http.go l2met.go

func Counter Uses

func Counter(name string, value int) ln.Fer

Counter formats a value as a metrics counter.

func Gauge Uses

func Gauge(name string, value int) ln.Fer

Gauge formats a value as a metrics gauge.

func HTTPLog Uses

func HTTPLog(next http.Handler) http.Handler

HTTPLog automagically logs HTTP traffic.

func Measure Uses

func Measure(name string, ts time.Time) ln.Fer

Measure formats a value as a metrics measure.

func NewGoEventLogger Uses

func NewGoEventLogger(ev trace.EventLog) ln.Filter

NewGoEventLogger will log ln information to a given trace.EventLog instance.

func NewGoTraceLogger Uses

func NewGoTraceLogger() ln.Filter

NewGoTraceLogger will log ln information to a golang.org/x/net/trace.Trace if it is present in the context of ln calls.

Package ex imports 7 packages (graph) and is imported by 8 packages. Updated 2019-03-23. Refresh now. Tools for package owners.