title: Rabbit connection won't close
body: <p>I have a batch (java application) with spring-rabbit 1.1.4 (and spring 3.1.2) for connection to rabbit (consumer), like this :</p>
  
  <pre><code>&lt;bean class="org.springframework.amqp.support.converter.JsonMessageConverter" name="jsonMessageConverter"&gt;
      &lt;property name="classMapper"&gt;
          &lt;bean class="com.mydomain.amqp.mapper.CustomClassMapper"/&gt;
      &lt;/property&gt;
  &lt;/bean&gt;
  
  &lt;rabbit:connection-factory id="connectionFactory"
                             host="${rabbitmq.host}" 
                             port="${rabbitmq.port}"
                             virtual-host="${rabbitmq.vhost}"
                             username="${rabbitmq.username}" 
                             password="${rabbitmq.password}"
                             /&gt;
  
  &lt;rabbit:template id="amqpTemplate" connection-factory="connectionFactory" message-converter="jsonMessageConverter" /&gt;
  </code></pre>
  
  <p>In application, I use rabbit template like this :</p>
  
  <pre><code>@Value("${rabbitmq.exchange.name}")
  private String exchange;
  @Value("${rabbitmq.routing.key}")
  private String routingKey;
  @Autowired
  private RabbitTemplate amqpTemplate;
  
  @Override
  public boolean sendMessage(BussinessMessage message) {
      amqpTemplate.convertAndSend(exchange, routingKey, message);
      return true;
  }
  </code></pre>
  
  <p>I start batch in script shell with java command. It work well and all java code execute, but linux process keep alive because connection with rabbit keep alive. In rabbit manager UI, if I close connection, linux process terminate.</p>
  
  <p>What I do wrong ? Thank !</p>