I want to build an application that will provide different public API’s for data that is collected by a set of LoRaWAN IoT sensors.
The data from the sensors is transmitted using LoRaWAN, and is provided through a MQTT broker. At the moment I successfully set up an application using InfluxDB, Telegraf and Grafana. I have setup a Telegraf mqtt_consumer input plugin to collect the data and stores the measurements in an InfluxDB database. Using Grafana I am able to visualize the current measurement values and the historical data. This solution is good for development and internal usage.
I would like to provide the data using a set of public API’s. I was thinking about a REST, a GraphQL and a MQTT API.
The raw data should not be available, only a filtered set of possibilities depending on the duration (last value, last hour, last 24 hours, last 7 days…). For each of those filters, I would like to limit the values by aggregating average values per minute, hour, day,… So far nothing special.
Together with the sensor values, I would like to provide some extra information about the sensors, like a meaningful name, description, location, and so on. I don’t have a lot of experience with these kinds of setups, but I don’t think its a good idea to store this information in the InfluxDB. Would ik be senseful to use a relational database like MySQL to store this information. It would surely behave in a relational way against the sensor values.
Is this a correct way to work with data that is related to the time series data? Or should I take another approach in this application? Any tips or suggestions are welcome.