heartbeat

package
v1.12.1 Latest Latest
Warning

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

Go to latest
Published: Jun 20, 2024 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AliveUntilHeightQuery

type AliveUntilHeightQuery func(context.Context) (int64, error)

type CurrentHeightQuery

type CurrentHeightQuery func(context.Context) (int64, error)

type Heart

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

func New

func New(i AliveUntilHeightQuery, j CurrentHeightQuery, k KeepAliveCall, keepAliveThreshold int64, appVersion string, locker sync.Locker) *Heart

func (*Heart) Beat

func (m *Heart) Beat(ctx context.Context, locker sync.Locker) error

func (*Heart) SetRetryFalloff

func (m *Heart) SetRetryFalloff(falloff time.Duration)

type KeepAliveCall

type KeepAliveCall func(context.Context, string) error

Jump to

Keyboard shortcuts

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