interception

package
v0.0.0-...-4d838b4 Latest Latest
Warning

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

Go to latest
Published: Dec 6, 2019 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Handler

func Handler(w http.ResponseWriter, r *http.Request)

Handler processes interception requests.

Extracting the event-type from the GitHub hook event header.

If we don't have a handler for this event-type, the handler returns the body, and a successful response, allowing unknown events through.

Otherwise, they're passed to a handler to decide whether or not to allow the interception to complete.

Types

type InterceptionFunc

type InterceptionFunc func(r *http.Request, body []byte) ([]byte, error)

InterceptionFunc returns the response body, and possibly an error. If the response body is nil, this will be returned to the client as an error, indicating that it should not continue.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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