public class RMQConnection extends Object implements io.dropwizard.lifecycle.Managed
| Constructor and Description |
|---|
RMQConnection(RMQConfig config,
com.codahale.metrics.MetricRegistry metricRegistry,
ExecutorService executorService) |
| Modifier and Type | Method and Description |
|---|---|
com.rabbitmq.client.Channel |
channel() |
void |
ensure(String queueName,
String exchange) |
void |
ensure(String queueName,
String exchange,
Map<String,Object> rmqOpts) |
void |
ensure(String queueName,
String routingQueue,
String exchange) |
void |
ensure(String queueName,
String routingQueue,
String exchange,
Map<String,Object> rmqOpts) |
com.codahale.metrics.health.HealthCheck |
healthcheck() |
com.rabbitmq.client.Channel |
newChannel() |
Map<String,Object> |
rmqOpts() |
Map<String,Object> |
rmqOpts(String deadLetterExchange) |
void |
start() |
void |
stop() |
public RMQConnection(RMQConfig config, com.codahale.metrics.MetricRegistry metricRegistry, ExecutorService executorService)
public void start()
throws Exception
start in interface io.dropwizard.lifecycle.ManagedExceptionpublic void ensure(String queueName, String exchange, Map<String,Object> rmqOpts) throws Exception
Exceptionpublic void ensure(String queueName, String routingQueue, String exchange) throws Exception
Exceptionpublic void ensure(String queueName, String routingQueue, String exchange, Map<String,Object> rmqOpts) throws Exception
Exceptionpublic com.codahale.metrics.health.HealthCheck healthcheck()
public void stop()
throws Exception
stop in interface io.dropwizard.lifecycle.ManagedExceptionpublic com.rabbitmq.client.Channel channel()
throws IOException
IOExceptionpublic com.rabbitmq.client.Channel newChannel()
throws IOException
IOExceptionCopyright © 2016–2019. All rights reserved.