Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func New ¶
New creates new RabbitMQ health check that verifies the following: - connection establishing - getting channel from the connection - declaring topic exchange - declaring queue - binding a queue to the exchange with the defined routing key - publishing a message to the exchange with the defined routing key - consuming published message
Types ¶
type Config ¶
type Config struct { // DSN is the RabbitMQ instance connection DSN. Required. DSN string // Exchange is the application health check exchange. If not set - "health_check" is used. Exchange string // RoutingKey is the application health check routing key within health check exchange. // Can be an application or host name, for example. // If not set - host name is used. RoutingKey string // Queue is the application health check queue, that binds to the exchange with the routing key. // If not set - "<exchange>.<routing-key>" is used. Queue string // ConsumeTimeout is the duration that health check will try to consume published test message. // If not set - 3 seconds ConsumeTimeout time.Duration // DialTimeout is the duration that health check will try to dial to RabbitMQ. // If not set - 200 milliseconds. DialTimeout time.Duration }
Config is the RabbitMQ checker configuration settings container.
Click to show internal directories.
Click to hide internal directories.