queuex

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Jun 5, 2020 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Overview

Package queuex provides primitives for communicating with all queue

Package queuex provides primitives for communicating with all queue

Package queuex provides primitives for communicating with all queue

Package queuex provides primitives for communicating with all queue

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BeanstalkController

type BeanstalkController struct {
	Config *oldmonkv1.ListOptions
	Client *beanstalk.Tube
}

BeanstalkController hold configration and client for beanstalkd queue

func NewBeanstalkClient

func NewBeanstalkClient(config *oldmonkv1.ListOptions) *BeanstalkController

NewBeanstalkClient create a new BeanstalkController object It returns the BeanstalkController

func (*BeanstalkController) Close

func (r *BeanstalkController) Close() error

Close will close beanstalk connection It returns the error

func (*BeanstalkController) GetCount

func (b *BeanstalkController) GetCount() int32

GetCount count the number of message in a tube It returns the number of Messages in a tube

type NatsController

type NatsController struct {
	Client *nats.Conn
	Config *oldmonkv1.ListOptions
}

NatsController hold configration and client for sqs

func NewNatsClient

func NewNatsClient(config *oldmonkv1.ListOptions) *NatsController

NewNatsClient create a new NatsController object It returns the NatsController

func (*NatsController) Close

func (r *NatsController) Close() error

Close will close sqs connection It returns the error

func (*NatsController) GetCount

func (r *NatsController) GetCount() int32

GetCount count the number of message in a queue It returns the number of Messages in a queue

type QueueFactory

type QueueFactory interface {
	GetCount() int32
	Close() error
}

QueueFactory hold Interface for queue client

func NewQueueConnection

func NewQueueConnection(queueType string, config *oldmonkv1.ListOptions) QueueFactory

NewQueueConnection create a new QueueFactory interface It returns the QueueFactory

type RabbitmqController

type RabbitmqController struct {
	Config  *oldmonkv1.ListOptions
	Channel *amqp.Channel
}

RabbitmqController hold configration and client for rabbitmq queue

func NewRabbitmqClient

func NewRabbitmqClient(config *oldmonkv1.ListOptions) *RabbitmqController

NewRabbitmqClient create a new RabbitmqController object It returns the RabbitmqController

func (*RabbitmqController) Close

func (r *RabbitmqController) Close() error

Close will close rabbitmq channel It returns the error

func (*RabbitmqController) GetCount

func (r *RabbitmqController) GetCount() int32

GetCount count the number of message in a queue It returns the number of Messages in a queue

type SqsController

type SqsController struct {
	Client *sqs.SQS
	Config *oldmonkv1.ListOptions
}

SqsController hold configration and client for sqs

func NewSqsClient

func NewSqsClient(config *oldmonkv1.ListOptions) *SqsController

NewSqsClient create a new SqsController object It returns the SqsController

func (*SqsController) Close

func (r *SqsController) Close() error

Close will close sqs connection It returns the error

func (*SqsController) GetCount

func (r *SqsController) GetCount() int32

GetCount count the number of message in a queue It returns the number of Messages in a queue

Jump to

Keyboard shortcuts

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