0

As stated in the title: How can I add / remove a single or multiple topics to a started MQTT inbound adapter at runtime without stopping and resubscribing?

I am using a similar configuration to the example from docs.spring.io:

<int-mqtt:message-driven-channel-adapter id="mqttInbound"
client-id="${mqtt.default.client.id}.src"
url="${mqtt.url}"
topics="topic1, topic2, topic3"
client-factory="clientFactory"
channel="output"/>
Hasib Samad
  • 1,081
  • 1
  • 20
  • 39

1 Answers1

2

Dynamically changing the subscribed topics is not currently supported. Please open an Improviement JIRA Issue.

Gary Russell
  • 166,535
  • 14
  • 146
  • 179
  • 1
    In case it's not clear, topics can include wildcards so that might be a viable work-around. See the Paho javadocs for more information. – Gary Russell Jul 09 '14 at 14:51