httpcache

package module
v0.1.0-alpha.6 Latest Latest
Warning

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

Go to latest
Published: Feb 26, 2021 License: MIT Imports: 17 Imported by: 0

README

Caddy Cache-Handler

Stores

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Cache

type Cache struct {
	Config   config.Config
	Store    stores.CacheStore
	Deciders []func(c config.Config, w http.ResponseWriter, r *http.Request) bool
	// contains filtered or unexported fields
}

Cache stuff

func (Cache) CaddyModule

func (Cache) CaddyModule() caddy.ModuleInfo

CaddyModule returns the Caddy module information.

func (*Cache) Provision

func (c *Cache) Provision(ctx caddy.Context) error

Provision _

func (*Cache) ServeHTTP

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

func (*Cache) UnmarshalCaddyfile

func (c *Cache) UnmarshalCaddyfile(d *caddyfile.Dispenser) error

UnmarshalCaddyfile sets up the handler from Caddyfile tokens. Syntax:

cache {
	expire 120                              # Cache expiration in seconds
	method post                             # HTTP Methods you want to bypass
	bypass wp-admin wp-login.php system     # WordPress and ExpressionEngine
	# cookie exp_sessionid                  # ExpressionEngine
	cookie wordpress_logged_in_.*           # WordPress
}

This may change.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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