request

package
v0.22.0 Latest Latest
Warning

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

Go to latest
Published: Feb 10, 2017 License: Apache-2.0 Imports: 5 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type HookRequest

type HookRequest struct {
	Record   interface{} `json:"record"`
	Original interface{} `json:"original"`
}

HookRequest contains records involved in a database hook.

type Request

type Request struct {
	Context context.Context
	Kind    string
	Name    string
	Param   interface{}
}

Request represents data in a server to worker plugin request.

func NewAuthRequest

func NewAuthRequest(ctx context.Context, authReq *skyplugin.AuthRequest) *Request

NewAuthRequest creates a new auth request.

func NewEventRequest

func NewEventRequest(name string, data json.RawMessage) *Request

NewEventRequest creates a new event request

func NewHandlerRequest

func NewHandlerRequest(ctx context.Context, name string, input json.RawMessage) *Request

NewHandlerRequest creates a new handler request.

func NewHookRequest

func NewHookRequest(ctx context.Context, hookName string, record *skydb.Record, originalRecord *skydb.Record) *Request

NewHookRequest creates a new hook request.

func NewLambdaRequest

func NewLambdaRequest(ctx context.Context, name string, args json.RawMessage) *Request

NewLambdaRequest creates a new lambda request.

func NewTimerRequest added in v0.22.0

func NewTimerRequest(name string) *Request

NewTimerRequest creates a new timer request.

func (*Request) MarshalJSON

func (req *Request) MarshalJSON() ([]byte, error)

MarshalJSON converts a request to JSON representation.

Jump to

Keyboard shortcuts

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