Description

The MQTT sender plugin forwards 1Gateway messages to a MQTT broker.

Prerequisites

The MQTT sender requires 1Gateway and SDK version 3.2.0.

Installation

Make sure you have the 1gateway zip file that includes the plugin files and valid licences information ready. This file has been provided to you with the installation files.

1 - Login

Login to 1gateway, and make sure you are in "Advanced mode". If this is the first time you log in, the default user and password are both 'admin' (without the quotes).

2 - System Maintenance

Click on the menu icon and choose the option "System maintenance"


3 - Upload file


In the System maintenance view you can either drag and drop the downloaded zip file or select it by clicking the "choose file" button.

Configuration


Open the main menu and click on "New plugin"

Select the plugin you want to configure. Use the Filter field if needed.

Field name

Supported values

Description

URL

Any string

Configure the connection to the MQTT broker, include protocol and port information

UserAny stringUser name
PasswordAny stringPassword
Default topicAny stringDefine the default topic used when forwarding the message to the broker
Topic from messageAny stringSet topic by using either a field from the source or the target message defined in a mapping

Generic sender plugin configuration


The following configuration fields are generic for all sender plugins.

Field nameSupported valuesDescription
Process 1Gateway messages (outboud)TickboxIf unticked, the plugin doesn't get any messages
TopicsFormatted string

String in the format: origin_endpoint.message_type.phase
To define more than one topic, separate with semicolon (;)

For more information on queues, click here.

QueuenameAny stringName of the queue in RabbitMQ. 
DurableTickboxIf ticked, will save the messages in the queue to disk when 1Gateway is down.
PrefechAny integerHow many messages to get from RabbitMQ at a time
ThreadsAny integerHow many threads to run in the sender
Filter expressionGroovy scriptGroovy expression that returns true if the filter has passed or false if it hasn't. If the filter does not pass for a specific message, that message won't get processed by the plugin. For more information on filters, click here.

See also