Documentation ¶
Index ¶
- Variables
- type AwaitForBodyHandler
- type Body
- type BodyHandler
- type Config
- func (c Config) GetConsumer(name string) (ConsumerConfig, error)
- func (c Config) GetExchange(name string) (ExchangeConfig, error)
- func (c Config) GetProducer(name string) (ProducerConfig, error)
- func (c Config) GetQueue(name string) (QueueConfig, error)
- func (c Config) GetQueueBind(name string) ([]QueueBindConfig, error)
- func (c Config) GetRoute(i interface{}) (RouteConfig, error)
- type Consumer
- type ConsumerConfig
- type Controller
- type ExchangeConfig
- type ExchangeKind
- type Handled
- type MessageType
- type NoReply
- type Producer
- type ProducerConfig
- type PublishMessage
- type PublishedMessage
- type QueueBindConfig
- type QueueConfig
- type RouteConfig
Constants ¶
This section is empty.
Variables ¶
View Source
var ConfigNotFound = errors.New("config not found")
Functions ¶
This section is empty.
Types ¶
type AwaitForBodyHandler ¶ added in v0.5.0
type AwaitForBodyHandler struct { Handler BodyHandler // contains filtered or unexported fields }
func WaitForReply ¶ added in v0.4.0
func WaitForReply[T interface{}](i T) (*AwaitForBodyHandler, *T)
func (*AwaitForBodyHandler) Done ¶ added in v0.5.0
func (h *AwaitForBodyHandler) Done()
func (*AwaitForBodyHandler) Wait ¶ added in v0.5.0
func (h *AwaitForBodyHandler) Wait()
type BodyHandler ¶ added in v0.5.0
type Config ¶
type Config struct {
// contains filtered or unexported fields
}
func NewConfig ¶
func NewConfig( consumers map[string]ConsumerConfig, exchanges map[string]ExchangeConfig, queues map[string]QueueConfig, queueBindings map[string][]QueueBindConfig, producers map[string]ProducerConfig, routing map[interface{}]RouteConfig, ) Config
func (Config) GetConsumer ¶
func (c Config) GetConsumer(name string) (ConsumerConfig, error)
func (Config) GetExchange ¶
func (c Config) GetExchange(name string) (ExchangeConfig, error)
func (Config) GetProducer ¶
func (c Config) GetProducer(name string) (ProducerConfig, error)
func (Config) GetQueueBind ¶ added in v0.7.0
func (c Config) GetQueueBind(name string) ([]QueueBindConfig, error)
func (Config) GetRoute ¶
func (c Config) GetRoute(i interface{}) (RouteConfig, error)
type ConsumerConfig ¶
type Controller ¶
type Controller struct { *Producer // contains filtered or unexported fields }
type ExchangeConfig ¶
type ExchangeKind ¶ added in v0.7.0
type ExchangeKind string
const ( ExchangeDirect ExchangeKind = amqp.ExchangeDirect ExchangeFanout ExchangeKind = amqp.ExchangeFanout ExchangeTopic ExchangeKind = amqp.ExchangeTopic ExchangeHeaders ExchangeKind = amqp.ExchangeHeaders )
func (ExchangeKind) String ¶ added in v0.7.0
func (e ExchangeKind) String() string
type Handled ¶
type Handled struct {
// contains filtered or unexported fields
}
func HandledAndRejected ¶
func HandledAndRejected() Handled
func HandledNotSuccessfully ¶
func HandledSuccessfully ¶
func HandledSuccessfully() Handled
type MessageType ¶
type MessageType string
const ( MessageRegular MessageType = "regular" MessageWithReply MessageType = "with_reply" )
type Producer ¶ added in v0.3.0
type Producer struct {
// contains filtered or unexported fields
}
func (Producer) Publish ¶ added in v0.3.0
func (p Producer) Publish(msg PublishMessage) (PublishedMessage, error)
type ProducerConfig ¶
type PublishMessage ¶
type PublishMessage struct {
// contains filtered or unexported fields
}
func MessageToPublish ¶
func MessageToPublish(msg interface{}) PublishMessage
func MessageToPublishWithReply ¶
func MessageToPublishWithReply(msg interface{}, handler BodyHandler) PublishMessage
type PublishedMessage ¶
type QueueBindConfig ¶ added in v0.7.0
type QueueConfig ¶
type RouteConfig ¶
type RouteConfig struct {
Producer string
}
Click to show internal directories.
Click to hide internal directories.