input

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Feb 23, 2023 License: MIT Imports: 9 Imported by: 0

Documentation

Overview

Copyright (c) 2023 Albert Espín albert@espin.ovh

Copyright (c) 2023 Albert Espín albert@espin.ovh

Index

Constants

View Source
const (
	MaxDataBuffer int = 4096
)

Variables

View Source
var (
	ConnectionNr int = 0
)

Functions

This section is empty.

Types

type Injector

type Injector struct {
	fb.BaseProcess
	// contains filtered or unexported fields
}

func NewInjector

func NewInjector(config *InjectorConfig, net *fb.Network, log logger.LoggerAdapter) *Injector

func (*Injector) Out

func (inj *Injector) Out() *fb.OutPort

func (*Injector) Run

func (inj *Injector) Run()

type InjectorConfig

type InjectorConfig struct {
	// Process Name
	ProcessName string
	//
	Interval time.Duration
}

type NSQSubscriber

type NSQSubscriber struct {
	fb.BaseProcess
	// contains filtered or unexported fields
}

func NewNSQSubscriber

func NewNSQSubscriber(config *SubscriberConfig, net *fb.Network, log logger.LoggerAdapter) *NSQSubscriber

func (*NSQSubscriber) Close

func (s *NSQSubscriber) Close() error

Close implements Subscriber

func (*NSQSubscriber) In

func (s *NSQSubscriber) In() *fb.InPort

func (*NSQSubscriber) Out

func (s *NSQSubscriber) Out() *fb.OutPort

func (*NSQSubscriber) Run

func (s *NSQSubscriber) Run()

type SubscriberConfig

type SubscriberConfig struct {
	// Process Name
	ProcessName string
	// URL
	URL string
	// NSQ config
	NSQConfig *nsq.Config
	// Channel is the channel to subscribe to.
	Channel string
	// Topic
	Topic string
}

type TCPServer

type TCPServer struct {
	fb.BaseProcess
	// contains filtered or unexported fields
}

func NewTCPServer

func NewTCPServer(config *TCPServerConfig, net *fb.Network, log logger.LoggerAdapter) *TCPServer

func (*TCPServer) In

func (s *TCPServer) In() *fb.InPort

func (*TCPServer) Out

func (s *TCPServer) Out() *fb.OutPort

func (*TCPServer) Run

func (s *TCPServer) Run()

type TCPServerConfig

type TCPServerConfig struct {
	// Process name
	ProcessName string
	// Address tcp bind address
	Address string
	// DeadLine time
	DeadLine time.Duration
}

Jump to

Keyboard shortcuts

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