# A Reliable Publish-Subscribe Mechanism for Internet of Things-Enabled Smart Greenhouses
## 5 Conclusions and Future Work  
This article presents and assesses a reliable pub-sub mechanism and a standardized topic structure that exhibits significant scalability for the protocol utilized in IoT-enabled smart greenhouses. The proposed topic structure facilitates effective communication and comprehensive coverage of any modifications taking place within the various components of the greenhouse environment, hence resulting in enhanced plant monitoring and management. The proposed pub-sub system aims to optimize the utilization of resources in the MQTT broker architecture by minimizing the number of bytes per topic, message load, and overall data volume. This study emphasizes the significance of reducing the overall volume of transmitted data, complexity, cost, and server processing in a modified MQTT broker. The objective is to improve the scalability, simplicity, and efficiency of the system by minimizing the reception of irrelevant message data and reducing data duplication. This is achieved through the assignment of data to their respective topics. The proposed communication architecture does not need the customization of the brokers, namely, Mosquito 1.4.15, Beyywise MQTT Route 2.0, ActiveMQ 5.15.8, and EMQ X 4.0.8. Therefore, it is feasible to employ any existing broker to transmit messages with a standardized format from the greenhouse to the primary server. The assessment demonstrates that our system is capable of efficiently handling a substantial number of subscribers and promptly disseminating messages to them via the subscription key factor with high throughput. This factor directly influences the system's responsiveness and communication efficiency.  
To ascertain the extent of our contribution, we evaluated our proposed mechanism across several MQTT brokers and performed a comparative analysis with relevant papers in the field. The process of categorizing topics enables the collection and analysis of data purposefully. This capability has the potential to be advantageous in the monitoring and enhancement of system performance.  
Despite the promising results, this study has several limitations that need to be addressed to understand the full potential and limitations of the proposed method in real-world applications. While the proposed design improves scalability and efficiency, its primary focus is on MQTT brokers. Subsequent research should investigate the incorporation of other IoT communication protocols, such as CoAP, to ascertain their compatibility and performance in comparable applications. Likewise, the present system's dependence on pre-existing MQTT brokers, not customization, may restrict its capacity to use sophisticated functionalities that have become exclusive to certain broker implementations. Subsequent studies should explore the potential advantages of tailoring brokers to enhance performance optimization. The research did not investigate the security implications of the suggested design. Considering the growing significance of cybersecurity in IoT systems, future endeavors need to tackle possible weaknesses and integrate strong security measures to protect the data and infrastructure.  
Conceptualization, B.M.; Methodology, B.M.; Validation, B.V.; Formal analysis, B.M.; Investigation, B.M.; Resources, B.V.; Writing--original draft, B.M.; Writing--review & editing, B.V.; Supervision, B.V. All authors have read and agreed to the published version of the manuscript. This research received no external funding. Not applicable. Not applicable. Not applicable. Not applicable. Data Availability Statement: The data presented in this study are available in the article. The authors declare no conflict of interest.