ginrus

package
v0.0.0-...-c1c6bf0 Latest Latest
Warning

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

Go to latest
Published: May 8, 2024 License: MIT Imports: 3 Imported by: 207

README

cache

EOL-warning

This package has been abandoned on 2018-10-31. Please use gin-contrib/logger instead.

Documentation

Overview

Package ginrus provides log handling using logrus package.

Based on github.com/stephenmuss/ginerus but adds more options.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Ginrus

func Ginrus(logger loggerEntryWithFields, timeFormat string, utc bool) gin.HandlerFunc

Ginrus returns a gin.HandlerFunc (middleware) that logs requests using logrus.

Requests with errors are logged using logrus.Error(). Requests without errors are logged using logrus.Info().

It receives:

  1. A time package format string (e.g. time.RFC3339).
  2. A boolean stating whether to use UTC time zone or local.

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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