Movatterモバイル変換


[0]ホーム

URL:


middleware

package
v2.0.0-beta.5Latest Latest
Warning

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

Go to latest
Published: Nov 27, 2025 License:Apache-2.0Imports:15Imported by:0

Details

Repository

github.com/moby/moby

Links

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

funcDebugRequestMiddleware

func DebugRequestMiddleware(handler func(ctxcontext.Context, whttp.ResponseWriter, r *http.Request, vars map[string]string)error) func(ctxcontext.Context, whttp.ResponseWriter, r *http.Request, vars map[string]string)error

DebugRequestMiddleware dumps the request to logger

Types

typeExperimentalMiddleware

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

ExperimentalMiddleware is a the middleware in charge of adding the'Docker-Experimental' header to every outgoing request

funcNewExperimentalMiddleware

func NewExperimentalMiddleware(experimentalEnabledbool)ExperimentalMiddleware

NewExperimentalMiddleware creates a new ExperimentalMiddleware

func (ExperimentalMiddleware)WrapHandler

func (eExperimentalMiddleware) WrapHandler(handler func(ctxcontext.Context, whttp.ResponseWriter, r *http.Request, vars map[string]string)error) func(ctxcontext.Context, whttp.ResponseWriter, r *http.Request, vars map[string]string)error

WrapHandler returns a new handler function wrapping the previous one in the request chain.

typeMiddleware

type Middleware interface {WrapHandler(func(ctxcontext.Context, whttp.ResponseWriter, r *http.Request, vars map[string]string)error) func(ctxcontext.Context, whttp.ResponseWriter, r *http.Request, vars map[string]string)error}

Middleware is an interface to allow the use of ordinary functions as Docker API filters.Any struct that has the appropriate signature can be registered as a middleware.

typeVersionMiddleware

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

VersionMiddleware is a middleware thatvalidates the client and server versions.

funcNewVersionMiddleware

func NewVersionMiddleware(serverVersion, defaultAPIVersion, minAPIVersionstring) (*VersionMiddleware,error)

NewVersionMiddleware creates a VersionMiddleware with the given versions.

func (VersionMiddleware)WrapHandler

func (vVersionMiddleware) WrapHandler(handler func(ctxcontext.Context, whttp.ResponseWriter, r *http.Request, vars map[string]string)error) func(ctxcontext.Context, whttp.ResponseWriter, r *http.Request, vars map[string]string)error

WrapHandler returns a new handler function wrapping the previous one in the request chain.

Source Files

View all Source files

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f orF : Jump to
y orY : Canonical URL
go.dev uses cookies from Google to deliver and enhance the quality of its services and to analyze traffic.Learn more.

[8]ページ先頭

©2009-2025 Movatter.jp