Example usage for org.springframework.integration.jms JmsTimeoutException JmsTimeoutException

List of usage examples for org.springframework.integration.jms JmsTimeoutException JmsTimeoutException

Introduction

In this page you can find the example usage for org.springframework.integration.jms JmsTimeoutException JmsTimeoutException.

Prototype

public JmsTimeoutException(String description) 

Source Link

Usage

From source file:org.springframework.integration.jms.JmsOutboundGateway.java

private void expire(String correlationId) {
    final SettableListenableFuture<AbstractIntegrationMessageBuilder<?>> future = this.futures
            .remove(correlationId);//from   w w w  .jav a  2  s .  c om
    if (future != null) {
        try {
            if (getRequiresReply()) {
                future.setException(new JmsTimeoutException("No reply in " + this.receiveTimeout + " ms"));
            } else {
                if (logger.isDebugEnabled()) {
                    logger.debug("Reply expired and reply not required for " + correlationId);
                }
            }
        } catch (Exception e) {
            logger.error("Exception while expiring future");
        }
    }
}