Login | Register

A Comparison of IoT Communication Libraries: APIs and Performances

Title:

A Comparison of IoT Communication Libraries: APIs and Performances

Lai, Jianbin, Céspedes, Sandra and Guéhéneuc, Yann-Gaël (2024) A Comparison of IoT Communication Libraries: APIs and Performances. Masters thesis, Concordia University.

[thumbnail of Lai_MCompSc_S2024.pdf]
Preview
Text (application/pdf)
Lai_MCompSc_S2024.pdf - Accepted Version
Available under License Spectrum Terms of Access.
2MB

Abstract

The Internet of Things (IoT) and the number of deployed IoT devices are growing exponentially nowadays. These devices play pivotal roles in diverse domains, e.g., smart homes. Given their constrained processing and memory capacities, IoT devices communicate with one another through specialized protocols.
The two main IoT communication protocols are the Constrained Application Protocol (CoAP) and Message Queuing Telemetry Transport (MQTT). By March 1, 2023, there were 35 public libraries of CoAP and 40 of MQTT. These libraries have different characteristics, including levels of completeness and runtime performances.
Because of diverse requirements in different domains, the same protocol/library does not apply to any applications. Consequently, developers must select a library (e.g., Californium, java-coap, Paho MQTT, or HiveMQ MQTT Client) but they do not have access to comprehensive and clear comparisons of the API and performance of these protocols and their implementations, impeding their ability to make informed choices.
In this thesis, we implement multiple IoT scenarios using the CoAP and MQTT protocols and several of their implementation libraries. We conduct a comprehensive comparative analysis based on API and performance metrics, including static metrics, packet sizes, and runtime performance.
We thus provide developers with evidence to choose between CoAP and MQTT protocols and their libraries. In future work, we will expand this work to include other IoT protocols and libraries, more scenarios and metrics.

Divisions:Concordia University > Gina Cody School of Engineering and Computer Science > Computer Science and Software Engineering
Item Type:Thesis (Masters)
Authors:Lai, Jianbin and Céspedes, Sandra and Guéhéneuc, Yann-Gaël
Institution:Concordia University
Degree Name:M. Comp. Sc.
Program:Computer Science
Date:31 January 2024
Thesis Supervisor(s):Céspedes, Sandra and Guéhéneuc, Yann-Gaël
ID Code:993717
Deposited By: Jianbin Lai
Deposited On:04 Jun 2024 15:05
Last Modified:04 Jun 2024 15:05

References:

[1] Kumar, Sumit and Dalal, Sumit and Dixit, Vivek. The OSI model: Overview on the seven layers of computer networks. International Journal of Computer Science and Information Technology Research, 2(3):461–466, 2014.
[2] Statista. Number of internet of things (IoT) connected devices worldwide from 2019 to 2030(in billions), 2022. URL https://www.statista.com/statistics/1183457/iot-connected-devices-worldwide/.
[3] Shelby, Zach and Hartke, Klaus and Bormann, Carsten. The constrained application protocol (CoAP), 2014. URL https://datatracker.ietf.org/doc/html/rfc7252.
[4] MQTT.org. MQTT: The Standard for IoT Messaging, 2022. URL https://mqtt.org/.
[5] Al Enany, Marwa O. and Harb, Hany M. and Attiya, Gamal. A Comparative analysis of MQTT and IoT application protocols. In 2021 International Conference on Electronic Engineering (ICEEM), pages 1–6, New York, NY, USA, 2021. IEEE CS Press. doi: 10.1109/ICEEM52022.2021.9480384.
[6] Laaroussi, Zakaria and Novo, Oscar. A Performance Analysis of the Security Communication in CoAP and MQTT. In 2021 IEEE 18th Annual Consumer Communications & Networking Conference (CCNC), pages 1–6, New York, 2021. IEEE CS Press. doi: 10.1109/CCNC49032.2021.9369565.
[7] Naik, Nitin. Choice of effective messaging protocols for IoT systems: MQTT, CoAP, AMQP and HTTP. In 2017 IEEE International Systems Engineering Symposium (ISSE), pages 1–7, New York, 2017. IEEE CS Press. doi: 10.1109/SysEng.2017.8088251.
[8] OASIS Message Queuing Telemetry Transport (MQTT) TC. MQTT Version 5.0, 2019. URL https://docs.oasis-open.org/mqtt/mqtt/v5.0/mqtt-v5.0.html.
[9] International Organization for Standardization. ISO/IEC 7498-1: 1994 information technology–open systems interconnection–basic reference model: The basic model. Inter-national Standard ISOIEC, 74981:59, 1996.
[10] IBM. Connecting all the things in the Internet of Things. URL https://developer.ibm.com/articles/iot-lp101-connectivity-network-protocols/.
[11] Microsoft. IoT technologies and protocols. URL https://azure.microsoft.com/en-ca/solutions/iot/iot-technology-protocols/.
[12] CISCO. IoT and Security Standards and Best Practices. URL https://www.ciscopress.com/articles/article.asp?p=2923211&seqNum=6.
[13] Stefanec, Tomislav and Kusek, Mario. Comparing energy consumption of application layer protocols on IoT devices. In 2021 16th International Conference on Telecommunications (ConTEL), pages 23–28, 2021. doi: 10.23919/ConTEL52528.2021.9495993.
[14] Jon Postel. Rfc0768: User datagram protocol, 1980.
[15] Klaus Hartke. Rfc 7641: Observing resources in the constrained application protocol (coap), 2015.
[16] Stanford-Clark, Andy and Truong, Hong Linh. Mqtt for sensor networks (mqtt-sn) protocol specification. International business machines (IBM) Corporation version, 1(2):1–28, 2013.
[17] Bormann, Carsten and Lemay, Simon and Tschofenig, Hannes and Hartke, Klaus and Silvera-jan, Bilhanan and Raymor, B. CoAP (Constrained Application Protocol) over TCP, TLS, and WebSockets, 2018. URL https://datatracker.ietf.org/doc/html/rfc8323.
[18] Selander, Göran and Mattsson, John and Palombini, Francesca and Seitz, Ludwig. Object security for constrained restful environments (oscore), 2019. URL https://datatracker.ietf.org/doc/html/rfc8613.
[19] Aline Brito, Laerte Xavier, Andre Hora, and Marco Tulio Valente. APIDiff: Detecting API breaking changes. In 2018 IEEE 25th International Conference on Software Analysis, Evolution and Reengineering (SANER), pages 507–511, 2018. doi: 10.1109/SANER.2018.8330249.
[20] Jang, Minwoo and Kook, Joongjin and Ryu, Samin and Lee, Kahyun and Shin, Sung and Kim, Ahreum and Park, Youngsu and Cho, Eig Hyun. An efficient similarity comparison based on core API calls. In Proceedings of the 28th Annual ACM Symposium on Applied Computing, pages 1634–1638, 2013.
[21] Raza, Shahid and Shafagh, Hossein and Hewage, Kasun and Hummen, René and Voigt, Thiemo. Lithe: Lightweight Secure CoAP for the Internet of Things. IEEE Sensors Journal, 13(10):3711–3720, 2013. doi: 10.1109/JSEN.2013.2277656.
[22] Kovatsch, Matthias and Lanter, Martin and Shelby, Zach. Californium: Scalable cloud services for the Internet of Things with CoAP. In 2014 International Conference on the Internet of Things (IOT), pages 1–6, 2014. doi: 10.1109/IOT.2014.7030106.
[23] Yassein, Muneer Bani and Shatnawi, Mohammed Q. and Aljwarneh, Shadi and Al-Hatmi, Razan. Internet of Things: Survey and open issues of MQTT protocol. In 2017 International Conference on Engineering & MIS (ICEMIS), pages 1–6, 2017. doi: 10.1109/ICEMIS.2017.8273112.
[24] Atmoko, Rachmad Andri and Riantini, Rona and Hasin, Muhammad Khoirul. IoT real time data acquisition using MQTT protocol. Journal of Physics: Conference Series, abstract = The Internet of Things (IoT) provides ease to monitor and to gain sensor data through the Internet [1]. The need of high quality data is increasing to the extent that data monitoring and acquisition system in real time is required, such as smart city or telediagnostic in medical areas [2]. Therefore, an appropriate communication protocol is required to resolve these problems. Lately, researchers have developed a lot of communication protocols for IoT, of which each has advantages and disadvantages. This study proposes the utilization of MQTT as a communication protocol, which is one of data communication protocols for IoT. This study used temperature and humidity sensors because the physical parameters are often needed as parameters of environment condition [3]. Data acquisition was done in real-time and stored in MySQL database. This study is also completed by interface web-based and mobile for online monitoring. This result of this study is the enhancement of data quality and reliability using MQTT protocol., 853(1):012003, may 2017. doi: 10.1088/1742-6596/853/1/012003. URL https://dx.doi.org/10.1088/1742-6596/853/1/012003.
[25] Thangavel, Dinesh and Ma, Xiaoping and Valera, Alvin and Tan, Hwee-Xian and Tan, Colin Keng-Yan. Performance evaluation of mqtt and coap via a common middleware. In 2014 IEEE Ninth International Conference on Intelligent Sensors, Sensor Networks and Information Processing (ISSNIP), pages 1–6, 2014. doi: 10.1109/ISSNIP.2014.6827678.
[26] He ̄di, Ivan and Špeh, I. and Šarabok, Antonio. IoT network protocols comparison for the purpose of IoT constrained networks. In 2017 40th International Convention on Information and Communication Technology, Electronics and Microelectronics (MIPRO), pages 501–505, 2017. doi: 10.23919/MIPRO.2017.7973477.
[27] Mawal Mohammed, Mahmoud Elish, and Abdallah Qusef. Empirical insight into the context of design patterns: Modularity analysis. In 2016 7th International Conference on ComputerScience and Information Technology (CSIT), pages 1–6. IEEE, 2016.
[28] Dennis Kafura and Geereddy R. Reddy. The use of software complexity metrics in software maintenance. IEEE Transactions on Software Engineering, SE-13(3):335–343, 1987. doi: 10.1109/TSE.1987.233164.
[29] Chidamber, Shyam R. and Kemerer, Chris F. A metrics suite for object oriented design. IEEE Transactions on Software Engineering, 20(6):476–493, 1994. doi: 10.1109/32.295895.
[30] McCabe, Thomas J. A Complexity Measure. IEEE Transactions on Software Engineering, SE-2(4):308–320, 1976. doi: 10.1109/TSE.1976.233837.
[31] Sci Tools. What metrics does understand have?, 2023. URL https://support.scitools.com/support/solutions/articles/70000582223-what-metrics-does-understand-have-2.
[32] Tanenbaum, Andrew S. and WETHERALL, DAVID J. Computer networks fifth edition, 2011.
[33] Peterson, Larry L. and Davie, Bruce S. 1 - foundation. In Peterson, Larry L. and Davie, BruceS., editor, Computer Networks (Fifth Edition), The Morgan Kaufmann Series in Networking, pages 1–69. Morgan Kaufmann, Boston, fifth edition edition, 2012. ISBN 978-0-12-385059-1. doi: https://doi.org/10.1016/B978-0-12-385059-1.00001-6. URL https://www.sciencedirect.com/science/article/pii/B9780123850591000016.
All items in Spectrum are protected by copyright, with all rights reserved. The use of items is governed by Spectrum's terms of access.

Repository Staff Only: item control page

Downloads per month over past year

Research related to the current document (at the CORE website)
- Research related to the current document (at the CORE website)
Back to top Back to top