Creating a Subscriber Service
Creating a Subscriber Service
A Subscriber Service allows your workspace to receive and process incoming sensor data through MQTT topics. By configuring a subscriber, you can store data in predefined tables and optionally use a custom MQTT broker or database. Follow the steps below to create and configure a subscriber service.
Steps to Create a Subscriber Service
- Navigate to Services > Subscribers.
- Click "Add New Subscriber".
-
Configure the subscriber with the following details:
Field Description Database Select the target database where data will be stored. MQTT Topic Define the topic where you will be sending payloads, formatted as: UPCARE/v2/WORKSPACE_ID/#
(e.g.,UPCARE/v2/CARE_2425_WEARABLE/#
).Container Name Format as WORKSPACE_ID_<description>
(e.g.,CARE_2425_WEARABLE_SUBSCRIBER
).Storage Preferences Choose whether to store data in the Data Table and/or Measurement Table. Optionally enable Payload Storage in a dedicated table. Debugging Enable Show Debugging Logs to monitor incoming messages. -
Optional Configurations:
-
Use Custom MQTT Broker (if not using the default broker):
Field Description MQTT Host URL The URL of the custom MQTT broker. Port Typically 8883
.User Defined in your MQTT broker. Password The authentication password for the MQTT broker. -
Use Custom Database (if not using the default database):
Field Description Host The hostname of the custom database. Port The port for database connection. User The database username. Password The database password. Use TLS Enable if using TLS encryption for secure communication. -
Use TLS: Enable if using TLS encryption for secure communication.
-
-
Click "Add", then select "Start Subscriber" to activate the service and begin processing data.
Once the subscriber is running, it will listen for MQTT messages on the specified topic and store data in the selected database. If you encounter issues with connectivity or data ingestion, check the Debugging Logs for troubleshooting.