Injected MessageListenerContainerRegistry error when spring.cloud.aws.sqs.enabled is false #869
Labels
component: sqs
SQS integration related issue
status: waiting-for-triage
Team has not yet looked into this issue
Hello everyone,
I'm not sure if this is a bug or more like a question on how to avoid.
I want to control the start and stop of containers based on feature flags, so I have a component with the MessageListenerContainerRegistry injected similar to what is on the documentation. I do something like this:
Then I was testing to add the option 'spring.cloud.aws.sqs.enabled' as false in the properties file. When starting the spring application it throws an error:
It seems there is no definition of an implementation for the registry interface when it is disabled.
I guess leaving the containers stopped has the same final effect as leaving this option disabled for us (no sqs processing) but would be good to have this to not break if someone tries to use it.
Any way to avoid the exception or should just not use this configuration property?
The text was updated successfully, but these errors were encountered: