Example usage for com.rabbitmq.client Connection abort

List of usage examples for com.rabbitmq.client Connection abort

Introduction

In this page you can find the example usage for com.rabbitmq.client Connection abort.

Prototype

void abort(int closeCode, String closeMessage, int timeout);

Source Link

Document

Abort this connection and all its channels.

Usage

From source file:org.ballerinalang.messaging.rabbitmq.util.ConnectionUtils.java

License:Open Source License

/**
 * Closes the connection.//from w  ww  .j a v  a 2  s .co m
 *
 * @param connection RabbitMQ Connection object.
 * @param timeout    Timeout (in milliseconds) for completing all the close-related operations, use -1 for infinity.
 */
private static void abortConnection(Connection connection, int closeCode, String closeMessage, int timeout) {
    connection.abort(closeCode, closeMessage, timeout);
}