Skip to content
This repository has been archived by the owner on Nov 20, 2024. It is now read-only.

RabbitMessageChannelBinder fails to initialize LocalizedQueueConnectionFactory if ssl.enabled is not specified #349

Closed
vkochnev opened this issue Nov 3, 2021 · 1 comment

Comments

@vkochnev
Copy link

vkochnev commented Nov 3, 2021

https://github.com/spring-cloud/spring-cloud-stream-binder-rabbit/blob/09c8b9bdc5a172b4034b32ff4d70b094ccb616b7/spring-cloud-stream-binder-rabbit/src/main/java/org/springframework/cloud/stream/binder/rabbit/RabbitMessageChannelBinder.java#L262

Shouldn't it be this.rabbitProperties.getSsl().determineEnabled() instead? The problem is if spring.rabbitmq.ssl.enabled is not specified in application.yml this line fails with NPE.

Also if virtualHost, username and/or password are specified on addresses instead of separate fields current implementation will ignore them, use of determine* alternatives might help here also (It looks like I should file these separately, but I'm not sure it makes sense).

More comprehensive solution might be discussed in spring-projects/spring-amqp#1384

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

No branches or pull requests

2 participants