request

package
v0.0.0-...-48d2764 Latest Latest
Warning

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

Go to latest
Published: Mar 4, 2024 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ParseRequestHandler

func ParseRequestHandler(h httpcaddyfile.Helper) (caddyhttp.MiddlewareHandler, error)

ParseRequestHandler parses the nats_request directive. Syntax:

nats_request [serverAlias] subject {
    [timeout 1s]
}

Types

type Request

type Request struct {
	Subject     string        `json:"subject,omitempty"`
	Timeout     time.Duration `json:"timeout,omitempty"`
	ServerAlias string        `json:"serverAlias,omitempty"`
	// contains filtered or unexported fields
}

func (Request) CaddyModule

func (Request) CaddyModule() caddy.ModuleInfo

func (*Request) Provision

func (p *Request) Provision(ctx caddy.Context) error

func (Request) ServeHTTP

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

func (*Request) UnmarshalCaddyfile

func (p *Request) UnmarshalCaddyfile(d *caddyfile.Dispenser) error

Jump to

Keyboard shortcuts

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