Hi Yeah we should maybe add a header to the Camel message from the MqttConsumer with the topic destination name from MQTT. Fell free to log a JIRA ticket.
MQTTDestination or something could be the header name. On Tue, May 20, 2014 at 1:20 PM, Carlo Simeone <r...@simeosoft.com> wrote: > Hi, > I'm using the Camel MQTT component with the following > uri (from karaf route-show): > > <?xml version="1.0" encoding="UTF-8" standalone="yes"?> > <route id="route4" xmlns="http://camel.apache.org/schema/spring"> > <from > uri="mqtt:testmqtt?host=tcp://localhost:1883&mqttTopicPropertyName=pippo&subscribeTopicName=topic/#"/> > <to uri="activemq:events" id="to2"/> > </route> > > in the JMS message there's no sign of the original topic. Assuming > is "topic/a/b" I was expecting some header showing the topic. > > I got only (from the Hawtio browsing tab): > > Header Value > Header - JMSCorrelationID > Header - JMSDeliveryMode PERSISTENT > Header - JMSDestination queue://events > Header - JMSExpiration 0 > Header - JMSMessageID ID:lenovo-50831-1400580839684-6:2:1:1:1 > Header - JMSPriority 4 > Header - JMSRedelivered false > Header - JMSReplyTo > Header - JMSTimestamp 2014-05-20T12:46:49+02:00 > Header - JMSType > Header - JMSXGroupID > Header - JMSXGroupSeq 0 > Header - JMSXUserID > Header - BodyLength 896 > Header - BrokerPath null > Header - OriginalDestination > String Property - breadcrumbId ID-lenovo-35129-1400580848377-4-3 > > > I was expecting something like: > Header - pippo topic/a/b > > Reading the docs it seems TopicPropertyName is used only by a MQTT producer > (http://camel.apache.org/mqtt.html -> mqttTopicPropertyName) > > > > TIA -- Claus Ibsen ----------------- Red Hat, Inc. Email: cib...@redhat.com Twitter: davsclaus Blog: http://davsclaus.com Author of Camel in Action: http://www.manning.com/ibsen hawtio: http://hawt.io/ fabric8: http://fabric8.io/