rabbitmq

package
v4.2.547+incompatible Latest Latest
Warning

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

Go to latest
Published: Dec 20, 2019 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DEFAULT_URL                       = "amqp://admin:adminpass@rabbitmq.alameda.svc.cluster.local:5672"
	DEFAULT_PUBLISH_RETRY_TIME        = 3
	DEFAULT_PUBLISH_RETRY_INTERVAL_MS = 500
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	URL   string `mapstructure:"url"`
	Retry *Retry `mapstructure:"retry"`
}

Configuration of weave scope

func NewDefaultConfig

func NewDefaultConfig() *Config

Provide default configuration for weave scope

func (*Config) Validate

func (c *Config) Validate() error

Confirm the configuration is validated

type RabbitMQSender

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

func NewRabbitMQSender

func NewRabbitMQSender(rabbitMQConfig *Config) (*RabbitMQSender, error)

func (*RabbitMQSender) Close

func (s *RabbitMQSender) Close() error

func (*RabbitMQSender) SendJsonString

func (s *RabbitMQSender) SendJsonString(queueName, jsonStr string) error

type Retry

type Retry struct {
	PublishTime       int   `mapstructure:"publishTime"`
	PublishIntervalMS int64 `mapstructure:"publishIntervalMs"`
}

Jump to

Keyboard shortcuts

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