redislogger

package
v0.0.0-...-187974e Latest Latest
Warning

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

Go to latest
Published: Aug 16, 2024 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type RedisLogger

type RedisLogger struct {
	RedisAddress  string        `json:"redis_address,omitempty"`
	RedisPassword string        `json:"redis_password,omitempty"`
	RedisDB       int           `json:"redis_db,omitempty"`
	RedisKey      string        `json:"redis_key"`
	WithBody      bool          `json:"with_body,omitempty"`
	DialTimeout   time.Duration `json:"dial_timeout,omitempty"`  // 连接超时时间
	ReadTimeout   time.Duration `json:"read_timeout,omitempty"`  // 读取超时时间
	WriteTimeout  time.Duration `json:"write_timeout,omitempty"` // 写入超时时间
	MaxRetries    int           `json:"max_retries,omitempty"`   // 最大重试次数
	// contains filtered or unexported fields
}

func (RedisLogger) CaddyModule

func (RedisLogger) CaddyModule() caddy.ModuleInfo

func (*RedisLogger) Cleanup

func (rl *RedisLogger) Cleanup() error

func (*RedisLogger) Provision

func (rl *RedisLogger) Provision(ctx caddy.Context) error

Provision实现了caddy.Provisioner

func (*RedisLogger) ServeHTTP

func (rl *RedisLogger) ServeHTTP(w http.ResponseWriter, r *http.Request, next caddyhttp.Handler) error

ServeHTTP 实现了 caddyhttp.MiddlewareHandler

func (*RedisLogger) UnmarshalCaddyfile

func (rl *RedisLogger) UnmarshalCaddyfile(d *caddyfile.Dispenser) error

UnmarshalCaddyfile实现了caddyfile.Unmarshaler

func (*RedisLogger) Validate

func (rl *RedisLogger) Validate() error

Validate实现了caddy.Validator

Jump to

Keyboard shortcuts

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