rbt

package
v0.0.32 Latest Latest
Warning

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

Go to latest
Published: Dec 30, 2024 License: GPL-3.0 Imports: 5 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ConsumeRabbitEvent added in v0.0.29

func ConsumeRabbitEvent[T any](
	fluentUrl string,
	rabbitUrl string,
	serverName string,
	exchangeName string,
	channelType string,
	queueName string,
	routingKey string,
	processIncomingMessage func(log.LogRusEntry, *InputMessage[T]),
) error

func RbtLogger added in v0.0.27

func RbtLogger(fluentUrl string, serverName string, correlationId string) log.LogRusEntry

Types

type InputMessage added in v0.0.29

type InputMessage[T any] struct {
	CorrelationId string `json:"correlation_id" example:"123123" `
	RoutingKey    string `json:"routing_key" example:"Remote RoutingKey to Reply"`
	Exchange      string `json:"exchange" example:"Remote Exchange to Reply"`
	Message       T
}

type RabbitPublisher added in v0.0.4

type RabbitPublisher[T any] interface {
	PublishForResult(data T, exchange string, routingKey string) error
	PublishTo(exchange string, routingKey string, data T) error
	Publish(data T) error
	Logger() log.LogRusEntry
}

func NewRabbitPublisher added in v0.0.4

func NewRabbitPublisher[T any](
	log log.LogRusEntry,
	rabbitURL string,
	exchangeName string,
	channelType string,
	routingKey string,
) (RabbitPublisher[T], error)

Jump to

Keyboard shortcuts

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