middleware

package
v0.0.0-...-eda81a1 Latest Latest
Warning

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

Go to latest
Published: May 22, 2024 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AuthMiddleware

func AuthMiddleware(auth config.Auth) func(http.Handler) http.Handler

func LogMiddleware

func LogMiddleware(producer SenderMessages) func(_ http.Handler) http.Handler

func SimpleLogMiddleware

func SimpleLogMiddleware() func(http.Handler) http.Handler

Types

type RequestInfo

type RequestInfo struct {
	URL      string              `json:"URL"`
	Headers  map[string][]string `json:"headers"`
	BodyData string              `json:"body"`
}

type SenderMessages

type SenderMessages interface {
	GetTopic() string
	SendAsyncMessage(message *sarama.ProducerMessage)
	Close() error
}

Jump to

Keyboard shortcuts

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