ticker

package
v0.0.23 Latest Latest
Warning

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

Go to latest
Published: Sep 29, 2022 License: MIT Imports: 5 Imported by: 0

Documentation

Overview

Package ticker offers an input carrier for the meander flow framework.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Carrier

type Carrier struct {
	Context  context.Context
	Logger   journal.Logger
	Interval time.Duration
}

Carrier defines the ticker carrier.

func New

func New(ctx context.Context, logger journal.Logger, config *Config) (*Carrier, error)

New initialises a new ticker carrier.

func (*Carrier) AcknowledgeMessage

func (c *Carrier) AcknowledgeMessage(m *flow.MessageContext, mErr error) error

AcknowledgeMessage is not relevant for this carrier.

func (*Carrier) InternalError

func (c *Carrier) InternalError(m *flow.MessageContext, mErr error) error

InternalError is not relevant for this carrier.

func (*Carrier) SetupInput

func (c *Carrier) SetupInput(inChan chan *flow.MessageContext) error

SetupInput creates a ticker and writes to inChan on every tick.

type Config

type Config struct {
	// Interval -- The interval of the ticker.
	Interval time.Duration
}

Jump to

Keyboard shortcuts

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