Documentation
¶
Overview ¶
Package rpc implmenets Python runtime
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AbstractRuntime ¶
type AbstractRuntime struct {
runtime.AbstractRuntime
// contains filtered or unexported fields
}
Runtime is a runtime that communicates via unix domain socket
func NewAbstractRuntime ¶
func NewAbstractRuntime(logger logger.Logger, configuration *runtime.Configuration, runtimeInstance Runtime) (*AbstractRuntime, error)
NewRPCRuntime returns a new RPC runtime
func (*AbstractRuntime) GetSocketType ¶
func (r *AbstractRuntime) GetSocketType() SocketType
GetSocketType returns the type of socket the runtime works with (unix/tcp)
func (*AbstractRuntime) ProcessEvent ¶
func (r *AbstractRuntime) ProcessEvent(event nuclio.Event, functionLogger logger.Logger) (interface{}, error)
ProcessEvent processes an event
func (*AbstractRuntime) WaitForStart ¶
func (r *AbstractRuntime) WaitForStart() bool
WaitForStart returns whether the runtime supports sending an indication that it started
type EventJSONEncoder ¶
type EventJSONEncoder struct {
// contains filtered or unexported fields
}
EventJSONEncoder encodes nuclio events as JSON
func NewEventJSONEncoder ¶
func NewEventJSONEncoder(logger logger.Logger, writer io.Writer) *EventJSONEncoder
NewEventJSONEncoder returns a new JSONEncoder
type Runtime ¶
type Runtime interface {
// RunWrapper runs the wrapper
RunWrapper(string) (*os.Process, error)
// GetSocketType returns the type of socket the runtime works with (unix/tcp)
GetSocketType() SocketType
// WaitForStart returns whether the runtime supports sending an indication that it started
WaitForStart() bool
}
type SocketType ¶
type SocketType int
SocketType is type of socket to use
const ( UnixSocket SocketType = iota TCPSocket )
RPC socket types
Click to show internal directories.
Click to hide internal directories.