Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

MQTT event publisher is used to send events to a MQTT broker based on the configurations you provide. You can configure it with XML, JSON, and text output mapping types.

Table of Contents
maxLevel3

Prerequisites 

Follow the steps below before starting the MQTT event publisher configuration. 

...

Adapter Property
Description
Configuration file propertyExample

Client Id

Client identifier is used by the server to identify a client when it reconnects, It used for durable subscriptions or reliable delivery of messages is required

clientId

test-client

Broker Url

MQTT broker URL. The same URL can be used f or WSO2 MB when offset=0

url
 tcp://localhost:1883
Username Username of the broker
username

mqtt-user

Password Password of the broker
password

mqtt-password

Clean Session Whether to persist topic subscriptions and acknowledge positions across client sessions
cleanSession
true/false
Quality of Service

Quality of service for delivering messages between clients and servers. There are three QoS levels in MQTT are as follows.

  • At most once (0)
  • At least once (1)
  • Exactly once (2)
qos
0,1,2

...

Adapter Property
Description
Configuration file propertyExample

Topic

 The topic that will be used to send messages to MQTT broker.

topic
sensordata