title: Spring RMQ listener always use PLAIN auth even after configuring SSL properties
body: <p>I have a spring boot application and I am trying to configure listeners to already existing queues. Following is what I configured in my <code>application.yml</code> file. I have also annotated my config class with <code>@EnableRabbit</code> and listener with <code>@RabbitListener</code> with appropriate configuration referring spring documentation.</p>
  
  <p>Please note that every property has a valid default value, I have removed them before posting them here.</p>
  
  <pre><code>spring:
    rabbitmq:
      host: ${rmq_host}
      port: ${rmq_port}
      virtualHost: ${rmq_virtual_host}
      requestedHeartbeat: ${rmq_requested_heartbeat_seconds}
      listener:
        simple:
          concurrency: ${rmq_listener_config_concurrent_users}
          autoStartup: ${rmq_listener_config_auto_startup}
          acknowledge-mode: ${rmq_listener_config_ack_mode}
      ssl:
        enabled: ${rmq_ssl_enabled:true}
        keyStore: ${rmq_ssl_keystore}
        keyStorePassword: ${rmq_ssl_keystore_password}
        trustStore: ${rmq_ssl_truststore}
        trustStorePassword: ${rmq_ssl_truststore_password}
  </code></pre>
  
  <p>With this configuration when I try to start the application it throws below exception. </p>
  
  <pre><code>org.springframework.amqp.rabbit.listener.exception.FatalListenerStartupException: Authentication failure
      at org.springframework.amqp.rabbit.listener.BlockingQueueConsumer.start(BlockingQueueConsumer.java:532)
      at org.springframework.amqp.rabbit.listener.SimpleMessageListenerContainer$AsyncMessageProcessingConsumer.run(SimpleMessageListenerContainer.java:1389)
      at java.lang.Thread.run(Thread.java:745)
  Caused by: org.springframework.amqp.AmqpAuthenticationException: com.rabbitmq.client.AuthenticationFailureException: ACCESS_REFUSED - Login was refused using authentication mechanism PLAIN. For details see the broker logfile.
      at org.springframework.amqp.rabbit.support.RabbitExceptionTranslator.convertRabbitAccessException(RabbitExceptionTranslator.java:65)
      at org.springframework.amqp.rabbit.connection.AbstractConnectionFactory.createBareConnection(AbstractConnectionFactory.java:368)
      at org.springframework.amqp.rabbit.connection.CachingConnectionFactory.createConnection(CachingConnectionFactory.java:565)
      at org.springframework.amqp.rabbit.connection.ConnectionFactoryUtils$1.createConnection(ConnectionFactoryUtils.java:90)
      at org.springframework.amqp.rabbit.connection.ConnectionFactoryUtils.doGetTransactionalResourceHolder(ConnectionFactoryUtils.java:140)
      at org.springframework.amqp.rabbit.connection.ConnectionFactoryUtils.getTransactionalResourceHolder(ConnectionFactoryUtils.java:76)
      at org.springframework.amqp.rabbit.listener.BlockingQueueConsumer.start(BlockingQueueConsumer.java:527)
      ... 2 common frames omitted
  Caused by: com.rabbitmq.client.AuthenticationFailureException: ACCESS_REFUSED - Login was refused using authentication mechanism PLAIN. For details see the broker logfile.
      at com.rabbitmq.client.impl.AMQConnection.start(AMQConnection.java:342)
      at com.rabbitmq.client.ConnectionFactory.newConnection(ConnectionFactory.java:909)
      at com.rabbitmq.client.ConnectionFactory.newConnection(ConnectionFactory.java:859)
      at com.rabbitmq.client.ConnectionFactory.newConnection(ConnectionFactory.java:799)
      at org.springframework.amqp.rabbit.connection.AbstractConnectionFactory.createBareConnection(AbstractConnectionFactory.java:352)
      ... 7 common frames omitted
  </code></pre>
  
  <p>While writing producers, I observed the same error which was resolved by setting sasl configurations to EXTERNAL but I could do it then as I was writing configuration beans on my own, here I am trying to use out of the box support from spring.</p>