## 1 Introduction  
The Internet of Things (IoT) is a novel paradigm that has become intertwined with the fabric of our daily life [1]. Advancement of IoT is bringing us ever closer to the realization of ubiquitous computing and pervasive networks [2, 3, 4, 5]. Initially, IoT was proposed to refer to radio frequency identification (RFID) tags [6], but today, the IoT domain includes devices such as RFID tags, sensors, actuators, and smartphones, amongst many other devices; they have become available and ubiquitous in every aspect of our lives, and these devices are influencing our decisions, behavior, and lifestyle. Generally, IoT devices are characterized by being small hardware devices that comprise four key enabling components, namely processing, memory storage, sensor(s), and communication components [6]. There are an almost unlimited number of applications for IoT, such as surveillance, environment monitoring, e-health, smart cities, lifestyle, transportation, learning, logistics, industrial manufacturing, agriculture, military, and automobile applications amongst many others applications [6, 7]. Wireless sensor networks and wireless IoT devices represent a specific subset of IoT devices. While they share many characteristics with general IoT devices, this subset faces additional challenges due to their deployment in inaccessible locations and at scales where recharging or replacing batteries is labor-intensive and inefficient. As a result, applicationsand approaches tailored to these devices must prioritize energy efficiency to enhance the longevity of the network [8; 9]. The capability of IoT devices to collect sensory data from the physical world and share them with other IoT devices or human users is increasingly bridging the gap between the physical and digital realms [3; 10; 11; 12; 13; 14; 15; 16; 17]. The affordability of these devices has significantly enhanced the availability and accessibility of sensory data [17]. Moreover, heterogeneous IoT devices can collaborate seamlessly, enabling machine-to-machine (M2M) interactions that occur without human intervention. This collaboration allows for the processing and aggregation of data, transforming locally collected sensory data into globally context-aware insights about the physical world [1; 2; 17; 18; 19]. The interoperability of these interconnected devices fosters a higher degree of intelligence within the network [1]. Nonetheless, the IoT paradigm presents new challenges, as IoT devices often face limitations in performance, resources, and cost [19]. To address these challenges, IoT applications must be efficient in utilizing the limited processing power, memory, and energy available in these devices [1]. Collected sensory data can be stored, processed, and communicated to derive meaningful insights [11]. However, storage and processing capabilities are constrained by the available resources on the IoT devices, which can be further limited by battery life and the energy required for data communication [11]. Additionally, communication within IoT networks can be unreliable and significantly slower than within traditional communication networks; thus, assuming that all nodes are avaliable and active in all scenarios many not be valid at all times [20]. Moreover, the large-scale deployment of IoT devices places substantial demands on backbone infrastructures, such as base-stations, servers, and cloud computing resources [21]. Raw sensory data must be processed to transform local observations into globally meaningful information and patterns. However, transmitting raw data through the network to centralized processing and storage can be overwhelming, especially given the vast volumes of sensory data generated by extensive IoT deployments [22]. In this context, geographically dispersed IoT devices can collaborate in parallel to optimize the use of their limited resources. Advancements in technology have made edge computing increasingly popular [23].