All Projects → apex → Log

apex / Log

Licence: mit
Structured logging package for Go.

Programming Languages

go
31211 projects - #10 most used programming language
golang
3204 projects

Projects that are alternatives of or similar to Log

Ios Sdk
AppSpector is a debugging service for mobile apps
Stars: ✭ 56 (-94.88%)
Mutual labels:  logging, logger
Heroku Logger
A dead simple logger, designed to be perfect for Heroku apps.
Stars: ✭ 57 (-94.79%)
Mutual labels:  logging, logger
Jslogger
Integrate JavaScript Logging with ASP.NET Core Logging APIs
Stars: ✭ 19 (-98.26%)
Mutual labels:  logging, logger
Qtwebapp
QtWebApp is a HTTP server like Java servlets, written in C++ with the Qt framework.
Stars: ✭ 50 (-95.43%)
Mutual labels:  logging, logger
Loglevelnext
A modern logging library for Node.js that provides log level mapping to the console
Stars: ✭ 33 (-96.98%)
Mutual labels:  logging, logger
Snoopy
Snoopy is a small library that logs all program executions on your Linux/BSD system (a.k.a. Snoopy Logger).
Stars: ✭ 835 (-23.67%)
Mutual labels:  logging, logger
Znetcs.aspnetcore.logging.entityframeworkcore
This is Entity Framework Core logger and logger provider. A small package to allow store logs in any data store using Entity Framework Core.
Stars: ✭ 24 (-97.81%)
Mutual labels:  logging, logger
Izumi
Productivity-oriented collection of lightweight fancy stuff for Scala toolchain
Stars: ✭ 423 (-61.33%)
Mutual labels:  logging, logger
Escriba
📜 Logging on steroids
Stars: ✭ 30 (-97.26%)
Mutual labels:  logging, logger
Cartus
A structured logging abstraction with multiple backends.
Stars: ✭ 21 (-98.08%)
Mutual labels:  logging, logger
Logbook
An extensible Java library for HTTP request and response logging
Stars: ✭ 822 (-24.86%)
Mutual labels:  logging, logger
Plog
Portable, simple and extensible C++ logging library
Stars: ✭ 1,061 (-3.02%)
Mutual labels:  logging, logger
G3log
G3log is an asynchronous, "crash safe", logger that is easy to use with default logging sinks or you can add your own. G3log is made with plain C++14 (C++11 support up to release 1.3.2) with no external libraries (except gtest used for unit tests). G3log is made to be cross-platform, currently running on OSX, Windows and several Linux distros. See Readme below for details of usage.
Stars: ✭ 677 (-38.12%)
Mutual labels:  logging, logger
Simplog
A simple logger. No dependencies, no special features, just logging.
Stars: ✭ 17 (-98.45%)
Mutual labels:  logging, logger
Gf
GoFrame is a modular, powerful, high-performance and enterprise-class application development framework of Golang.
Stars: ✭ 6,501 (+494.24%)
Mutual labels:  logging, logger
Thoth
An Error Logger for Go
Stars: ✭ 22 (-97.99%)
Mutual labels:  logging, logger
Concurrency Logger
Log HTTP requests/responses separately, visualize their concurrency and report logs/errors in context of a request.
Stars: ✭ 400 (-63.44%)
Mutual labels:  logging, logger
Quill
Asynchronous Low Latency C++ Logging Library
Stars: ✭ 422 (-61.43%)
Mutual labels:  logging, logger
Gollum
An n:m message multiplexer written in Go
Stars: ✭ 883 (-19.29%)
Mutual labels:  logging, logger
Browser Logger
A dead simple logger, designed to be perfect for the browser.
Stars: ✭ 44 (-95.98%)
Mutual labels:  logging, logger

Structured logging for golang

Package log implements a simple structured logging API inspired by Logrus, designed with centralization in mind. Read more on Medium.

Handlers

  • apexlogs – handler for Apex Logs
  • cli – human-friendly CLI output
  • discard – discards all logs
  • es – Elasticsearch handler
  • graylog – Graylog handler
  • json – JSON output handler
  • kinesis – AWS Kinesis handler
  • level – level filter handler
  • logfmt – logfmt plain-text formatter
  • memory – in-memory handler for tests
  • multi – fan-out to multiple handlers
  • papertrail – Papertrail handler
  • text – human-friendly colored output
  • delta – outputs the delta between log calls and spinner

Example

Example using the Apex Logs handler.

package main

import (
	"errors"
	"time"

	"github.com/apex/log"
)

func main() {
	ctx := log.WithFields(log.Fields{
		"file": "something.png",
		"type": "image/png",
		"user": "tobi",
	})

	for range time.Tick(time.Millisecond * 200) {
		ctx.Info("upload")
		ctx.Info("upload complete")
		ctx.Warn("upload retry")
		ctx.WithError(errors.New("unauthorized")).Error("upload failed")
		ctx.Errorf("failed to upload %s", "img.png")
	}
}

Build Status GoDoc

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].