webhook

package
v1.12.0-rc.1 Latest Latest
Warning

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

Go to latest
Published: Aug 9, 2023 License: AGPL-3.0 Imports: 26 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Init

func Init()

Types

type GatewayI

type GatewayI interface {
	IncrementRecvCount(count uint64)
	IncrementAckCount(count uint64)
	TrackRequestMetrics(errorMessage string)
	ProcessWebRequest(writer *http.ResponseWriter, req *http.Request, reqType string, requestPayload []byte, writeKey string) string
	GetWebhookSourceDefName(writeKey string) (name string, ok bool)
	NewSourceStat(writeKey, reqType string) *gwstats.SourceStat
	SaveWebhookFailures([]*model.FailedWebhookPayload) error
}

type HandleT

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

func Setup

func Setup(gwHandle GatewayI, stat stats.Stats, opts ...batchTransformerOption) *HandleT

func (*HandleT) Register

func (webhook *HandleT) Register(name string)

func (*HandleT) RequestHandler

func (webhook *HandleT) RequestHandler(w http.ResponseWriter, r *http.Request)

func (*HandleT) Shutdown

func (webhook *HandleT) Shutdown() error

type WebHookI

type WebHookI interface {
	RequestHandler(w http.ResponseWriter, r *http.Request)
	Register(name string)
}

type Webhook added in v1.9.0

type Webhook interface {
	RequestHandler(w http.ResponseWriter, r *http.Request)
	Register(name string)
	Shutdown() error
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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