handlers

package
v0.0.0-...-f822399 Latest Latest
Warning

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

Go to latest
Published: Apr 8, 2024 License: Apache-2.0 Imports: 22 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewImageHandler

func NewImageHandler(is imagestore.ImageStore, assistedServiceClient *AssistedServiceClient, maxRequests int64, mdw metricsmiddleware.Middleware) http.Handler

func NewLivenessHandler

func NewLivenessHandler() http.Handler

func WithCORSMiddleware

func WithCORSMiddleware(handler http.Handler, domains string) http.Handler

func WithInitrdViaHTTP

func WithInitrdViaHTTP(handler http.Handler) http.HandlerFunc

func WithRequestLimit

func WithRequestLimit(maxRequests int64) func(http.Handler) http.Handler

WithRequestLimit returns middleware that will limit the number of requests being concurrently handled to maxRequests. Blocks until a slot becomes available. A 503 response will be returned if the context expires or is cancelled while waiting.

Types

type AssistedServiceClient

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

func NewAssistedServiceClient

func NewAssistedServiceClient(assistedServiceScheme, assistedServiceHost, caCertFile string) (*AssistedServiceClient, error)

type BootArtifactsHandler

type BootArtifactsHandler struct {
	ImageStore imagestore.ImageStore
}

func (*BootArtifactsHandler) ServeHTTP

func (b *BootArtifactsHandler) ServeHTTP(w http.ResponseWriter, r *http.Request)

type ImageHandler

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

type ReadinessHandler

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

func NewReadinessHandler

func NewReadinessHandler() *ReadinessHandler

func (*ReadinessHandler) Enable

func (a *ReadinessHandler) Enable()

func (*ReadinessHandler) ServeHTTP

func (a *ReadinessHandler) ServeHTTP(w http.ResponseWriter, r *http.Request)

func (*ReadinessHandler) WithMiddleware

func (a *ReadinessHandler) WithMiddleware(next http.Handler) http.Handler

Jump to

Keyboard shortcuts

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