rpc

package
v0.0.0-...-455d6f4 Latest Latest
Warning

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

Go to latest
Published: Oct 15, 2026 License: LGPL-3.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type RpcWorkerPool

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

func NewRpcWorkerPool

func NewRpcWorkerPool(ctx context.Context) *RpcWorkerPool

func (*RpcWorkerPool) AfterApplicationCreation

func (p *RpcWorkerPool) AfterApplicationCreation(application driver.Application)

func (*RpcWorkerPool) AfterNodeCreation

func (p *RpcWorkerPool) AfterNodeCreation(newNode driver.Node)

func (*RpcWorkerPool) BeforeNodeRemoval

func (p *RpcWorkerPool) BeforeNodeRemoval(node driver.Node)

func (*RpcWorkerPool) Close

func (p *RpcWorkerPool) Close() error

func (*RpcWorkerPool) RegisterObserver

func (p *RpcWorkerPool) RegisterObserver(observer driver.TransactionObserver)

RegisterObserver adds an observer to be notified about every transaction this pool submits. Observers may be registered at any time; a transaction already submitted is not reported retroactively.

func (*RpcWorkerPool) RestrictApp

func (p *RpcWorkerPool) RestrictApp(app string, nodes []string)

RestrictApp makes the pool submit the transactions of the given application only through the nodes with the given labels, or through any node when there are none.

func (*RpcWorkerPool) SendTransaction

func (p *RpcWorkerPool) SendTransaction(tx *types.Transaction, source driver.TransactionSource)

SendTransaction hands the transaction to a worker of a node its application may submit through. When the chosen node is removed first, it tries another.

Jump to

Keyboard shortcuts

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