finality

package
v0.6.0 Latest Latest
Warning

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

Go to latest
Published: Oct 2, 2025 License: Apache-2.0 Imports: 19 Imported by: 4

Documentation

Index

Constants

This section is empty.

Variables

View Source
var TxNotFound = errors.New("tx not found")

Functions

func MaxUint64 added in v0.4.1

func MaxUint64(a, b uint64) uint64

func NewCommitterFLM added in v0.4.0

func NewCommitterFLM(committer *fabric.Committer) *committerListenerManager

func NewDeliveryFLM added in v0.4.0

func NewDeliveryFLM(logger logging.Logger, config events.DeliveryListenerManagerConfig, network string, ch *fabric.Channel) (*deliveryListenerManager, error)

Types

type DeliveryScanQueryByID added in v0.4.1

type DeliveryScanQueryByID[T events.EventInfo] struct {
	Logger   logging.Logger
	Delivery *fabric.Delivery
	Mapper   events.EventInfoMapper[T]
}

func (*DeliveryScanQueryByID[T]) QueryByID added in v0.4.1

func (q *DeliveryScanQueryByID[T]) QueryByID(ctx context.Context, lastBlock driver.BlockNum, evicted map[driver.TxID][]events.ListenerEntry[T]) (<-chan []T, error)

type FabricFinality added in v0.4.0

type FabricFinality struct {
	Logger                 logging.Logger
	Channel                string
	ConfigService          driver.ConfigService
	Services               Services
	DefaultSigningIdentity driver.SigningIdentity
	Hasher                 Hasher
	WaitForEventTimeout    time.Duration
	// contains filtered or unexported fields
}

func NewFabricFinality

func NewFabricFinality(
	logger logging.Logger,
	channel string,
	ConfigService driver.ConfigService,
	peerService Services,
	defaultSigningIdentity driver.SigningIdentity,
	hasher Hasher,
	waitForEventTimeout time.Duration,
	useFiltered bool,
) (*FabricFinality, error)

func (*FabricFinality) IsFinal added in v0.4.0

func (d *FabricFinality) IsFinal(txID string, address string) error

type Hasher

type Hasher interface {
	Hash(msg []byte) (hash []byte, err error)
}

type ListenerManager added in v0.4.0

type ListenerManager[T events.EventInfo] interface {
	AddEventListener(txID string, e events.ListenerEntry[T]) error
	RemoveEventListener(txID string, e events.ListenerEntry[T]) error
}

type Services added in v0.4.0

type Services interface {
	NewPeerClient(cc grpc.ConnectionConfig) (services.PeerClient, error)
}

Jump to

Keyboard shortcuts

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