rpc

package
v0.3.1 Latest Latest
Warning

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

Go to latest
Published: Aug 9, 2021 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Overview

This package is a wrapper around github.com/cadmean-ru/goRPCKit library adapted for Amphion tasks system.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Initialize

func Initialize(url string)

Initialize creates a new instance of rpc client with specified url.

Types

type FunctionCallBuilder added in v0.1.1

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

func F

func F(fName string) *FunctionCallBuilder

Creates a new call builder to call an RPC function with the specified name.

func (*FunctionCallBuilder) Call added in v0.1.1

func (f *FunctionCallBuilder) Call(args ...interface{})

Creates and runs task, calling the RPC function with given arguments.

func (*FunctionCallBuilder) Err added in v0.1.1

func (f *FunctionCallBuilder) Err(onError func(err error)) *FunctionCallBuilder

Specifies callback to be called when the RPC call finishes with an error.

func (*FunctionCallBuilder) Then added in v0.1.1

func (f *FunctionCallBuilder) Then(onSuccess func(res interface{})) *FunctionCallBuilder

Specifies callback to be called when the RPC call finishes successfully.

Jump to

Keyboard shortcuts

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