lib

package
v0.0.0-...-f69aefe Latest Latest
Warning

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

Go to latest
Published: May 22, 2024 License: Apache-2.0 Imports: 25 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type NativeExecutable

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

NativeExecutable execution provider implementation

func InitNexExecutionProviderNative

func InitNexExecutionProviderNative(params *agentapi.ExecutionProviderParams) (*NativeExecutable, error)

convenience method to initialize an ELF execution provider

func (*NativeExecutable) Deploy

func (e *NativeExecutable) Deploy() (err error)

Deploy the ELF binary

func (*NativeExecutable) Execute

func (e *NativeExecutable) Execute(ctx context.Context, payload []byte) ([]byte, error)

func (*NativeExecutable) Undeploy

func (e *NativeExecutable) Undeploy() error

Undeploy the ELF binary

func (*NativeExecutable) Validate

func (e *NativeExecutable) Validate() error

Validate the underlying artifact to be a 64-bit linux native ELF binary that is statically-linked

type OCI

type OCI struct {
}

OCI execution provider implementation

func InitNexExecutionProviderOCI

func InitNexExecutionProviderOCI(params *agentapi.ExecutionProviderParams) *OCI

InitNexExecutionProviderOCI convenience method to initialize an OCI execution provider

func (*OCI) Deploy

func (o *OCI) Deploy() error

func (*OCI) Execute

func (o *OCI) Execute(ctx context.Context, payload []byte) ([]byte, error)

func (*OCI) Undeploy

func (o *OCI) Undeploy() error

func (*OCI) Validate

func (o *OCI) Validate() error

type V8

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

V8 execution provider implementation

func InitNexExecutionProviderV8

func InitNexExecutionProviderV8(params *agentapi.ExecutionProviderParams) (*V8, error)

convenience method to initialize a V8 execution provider

func (*V8) Deploy

func (v *V8) Deploy() error

Deploy expects a `Validate` to have succeeded and `ubs` to be non-nil

func (*V8) Execute

func (v *V8) Execute(ctx context.Context, payload []byte) ([]byte, error)

Trigger execution of the deployed function; expects a `Validate` to have succeeded and `ubs` to be non-nil. The executed function can optionally return a value, in which case it will be deemed a reply and returned to the caller. In the case of a nil or empty value returned by the function, no reply will be sent.

func (*V8) Undeploy

func (v *V8) Undeploy() error

func (*V8) Validate

func (v *V8) Validate() error

Validate has the side effect of compiling the executable javascript source code and setting `ubs` on the underlying V8 execution provider instance.

type Wasm

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

Wasm execution provider implementation

func InitNexExecutionProviderWasm

func InitNexExecutionProviderWasm(params *agentapi.ExecutionProviderParams) (*Wasm, error)

InitNexExecutionProviderWasm convenience method to initialize a Wasm execution provider

func (*Wasm) Deploy

func (e *Wasm) Deploy() error

func (*Wasm) Execute

func (e *Wasm) Execute(ctx context.Context, payload []byte) ([]byte, error)

func (*Wasm) Undeploy

func (e *Wasm) Undeploy() error

func (*Wasm) Validate

func (e *Wasm) Validate() error

Jump to

Keyboard shortcuts

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