cache

package module
v2.10.1 Latest Latest
Warning

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

Go to latest
Published: Mar 12, 2022 License: MIT Imports: 16 Imported by: 0

README

cache

RRv2 RFC 7234 HTTP Cache middleware

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	// Driver name
	Driver string `mapstructure:"driver"`

	// Only get by default
	CacheMethods []string `mapstructure:"cache_methods"`

	// Driver specific configuration
	Config interface{} `mapstructure:"config"`
}

func (*Config) InitDefaults

func (c *Config) InitDefaults()

type Plugin

type Plugin struct {
	// contains filtered or unexported fields
}

func (*Plugin) CollectCaches

func (p *Plugin) CollectCaches(name endure.Named, cache cache.HTTPCacheFromConfig)

func (*Plugin) Collects

func (p *Plugin) Collects() []interface{}

func (*Plugin) Init

func (p *Plugin) Init(cfg config.Configurer, log *zap.Logger) error

func (*Plugin) Middleware

func (p *Plugin) Middleware(next http.Handler) http.Handler

func (*Plugin) Name

func (p *Plugin) Name() string

func (*Plugin) Serve

func (p *Plugin) Serve() chan error

func (*Plugin) Stop

func (p *Plugin) Stop() error

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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