EnjoyIot: An Open Source IoT Platform

Requirements

As a professional in the IoT industry, having worked on numerous IoT projects, the requirements for an IoT platform are very clear: 1.The supported protocols need to be numerous enough, with common protocols like MQTT and Modbus needing to be supported and easily extensible. 2.The system management must be comprehensive: user management, permission management, etc., are all essential. 3.A simple and flexible rules engine is required: it should support monitoring device online/offline status, attribute value anomalies, and be able to notify other business systems via message queues or HTTP, linking with other devices. 4.The code must be open source: there should not be various features only supported in commercial versions, and the core code must be open.

EnjoyIot

Based on the above clear requirements, after comparing a series of Java-based IoT platforms, I recommend a fully open-source IoT platform – EnjoyIot[1] EnjoyIot open-source IoT platform

As of the time of writing, it has over 2000 stars on Gitee.

IoT Features

First of all, the IoT features are very comprehensive, with protocol access and a rules engine available. For example:

1. Message forwarding, device alarms, and device linkage control can be configured through the web interface.

2. You can use the built-in MQTT server or connect to EMQX, ModbusTcp can be connected through web configuration.

3. The documentation is very complete, truly commendable, and the open-source community is very active. Documentation link[2]

4. It adopts a modern technology stack, with the front end using Vue3, TypeScript, and the back end using Spring Boot 2/3, MybatisPlus, Vertx, etc.

5. Excellent extensibility and compatibility, time-series databases can choose ES, TdEngine, etc. It supports changing message queues, with built-in Kafka, RocketMq, AKKA, etc., and supports horizontal scaling.

Product Management

Conveniently define various products, applicable to the object model and various protocol components, unified product management EnjoyIot: An Open Source IoT Platform Through the device detail page, you can read the current attribute values of the device, set writable attributes, and call methods provided by the device.

EnjoyIot: An Open Source IoT PlatformEnjoyIot: An Open Source IoT Platform

Rules Engine

The rules engine can adapt to different application scenarios, executing certain functions or data output forwarding through configured rules. For example, we need to monitor the online/offline status of devices, and when devices go online or offline, send notifications to administrators or maintenance personnel. Another example is when device data exceeds a certain value, an alarm is needed, or the data needs to be forwarded (via HTTP, Kafka, MQTT, etc.) to other platforms. At this time, the flexible rules engine configuration can complete the above application scenarios, facilitating operations and development.

For specific reference, see the official tutorial: Official tutorial[3]

EnjoyIot: An Open Source IoT Platform

Protocol Components

The protocol components are responsible for parsing device protocols. The design of EnjoyIot’s protocol components is, in my opinion, the simplest among these platforms and has high extensibility. Currently, it supports MQTT, HTTP, TCP, and ModbusTcp. It also provides detailed documentation: Official documentation – Device Access[4]

ModbusTcp Example:

First, configure the Modbus points of the product EnjoyIot: An Open Source IoT Platform Then enable the ModbusTcp plugin, which can poll the relevant points and report the corresponding information.

System Features

Secondly, the system management features are based on the Ruoyi framework, which basic Java developers are very familiar with, and the functionality is very comprehensive.

EnjoyIot: An Open Source IoT Platform

Function Description
User Management Users are system operators, and this function mainly completes system user configuration.
Online Users Monitoring the status of active users in the current system, supporting manual kick-off.
Role Management Role menu permission allocation, setting role buttons for data range permission division.
Menu Management Configuring system menus, operation permissions, button permission restrictions, etc., with local caching for performance.
Department Management Department system organizational structure (company, department, group), tree structure displaying existing data permissions.
Post Management Configuring the responsibilities undertaken by system users.
Tenant Management Configuring system tenants, supporting multi-tenant functionality in SaaS scenarios.
User Package Management Configuring tenant packages, customizing each tenant’s package, operations, and button permissions.
Dictionary Management Maintaining fixed data for frequently used data in the system.
SMS Management SMS channels, SMS templates, SMS logs, integrating with mainstream SMS platforms like Alibaba Cloud, Tencent Cloud, etc.
Email Management Email billing, email templates, email sending logs, supporting all email platforms.
Website Messages System message notifications, supporting internal message templates and messages.
Operation Logs Recording and querying normal operation logs of the system, integrating Swagger to generate log content.
Login Logs Recording and querying system login logs, including login anomalies.
Error Management Management of all system errors, allowing online modification of error messages without restarting the service.
Notifications and Announcements Publishing and maintaining system notifications and announcement information.
Sensitive Words Configuring system sensitive words, supporting tag grouping.
Application Management Managing SSO single sign-on applications, supporting various OAuth2 authorization methods.
Region Management Displaying province, city, district, and other city information, supporting IP to city mapping.

Basic Features

Rich basic features, allowing for easy secondary development EnjoyIot: An Open Source IoT Platform

Function Description
Code Generation Generation of front-end and back-end code (Java, Vue, SQL, unit tests), supporting CRUD downloads.
System Interfaces Automatically generating relevant RESTful API documentation based on Swagger.
Database Documentation Automatically generating database documentation based on Screw, supporting export in Word, HTML, MD formats.
Form Building Automatically generating HTML code for form examples, supporting export in JSON, Vue files.
Configuration Management Allowing dynamic configuration of parameter quantities in the system, supporting Spring Boot loading.
File Service Supporting file storage to S3 (MinIO, Alibaba Cloud, Tencent Cloud, Qiniu Cloud), local, FTP, database, etc.
WebSocket Providing WebSocket connection examples, supporting one-to-one and one-to-many sending methods.
API Logs Including RESTful API access logs and exception logs, facilitating troubleshooting of API-related issues.
MySQL Monitoring Monitoring the current database connection status, allowing for SQL analysis and system performance metrics.
Redis Monitoring Monitoring the usage of the Redis database, managing used Redis keys.
Message Queue Implementing a message queue based on Redis, with Stream providing cluster consumption and Pub/Sub providing broadcast consumption.
Java Monitoring Implementing monitoring of Java applications based on Spring Boot Admin.
Link Tracking Integrating the SkyWalking component to achieve link tracking.
Log Center Integrating the SkyWalking component to implement a log center.
Service Assurance Implementing distributed locks and rate limiting based on Redis to meet high concurrency access needs.
Monitoring Management A lightweight monitoring center to view logs from remote servers.

Others

In addition to the above aspects, in terms of extensibility, EnjoyIot stands out among many open-source projects.

References

<span>[1]</span> EnjoyIot: https://gitee.com/open-enjoy/enjoy-iot<span>[2]</span> Documentation link: https://y5yrmmjjns.feishu.cn/wiki/Fmgywh3zoiwhVnkdKyOcqfmLn0b?fromScene=spaceOverview<span>[3]</span> Official tutorial: https://y5yrmmjjns.feishu.cn/wiki/TRI8w6Mm2itiWkke37tcqXB7nlh<span>[4]</span> Official documentation – Device Access: https://y5yrmmjjns.feishu.cn/wiki/OwtIw5ARQiJwOAkQPL1cjEIfnEg

Leave a Comment