A Component-based Modeling of Edge Systems Computing O.N. Sehout, M. Ghiat Z. Benzadri, F. BELALA University of Constantine2-Abdelhamid Mehri LIRE Laboratory Faculty of NTIC University of Constantine2-Abdelhamid Mehri {nassim.sehout, mouad.ghiat}@univ-constantine2.dz {zakaria.benzadri, faiza.belala}@univ-constantine2.dz sensing devices which are connected to the Internet, challenges the traditional network architecture of the cloud computing framework. IoT envisions a new Abstract world of connected devices and humans in which quality of life is enhanced, because management of city Internet of Things (IoT) aims to bring every and its infrastructure is less cumbersome, health object, such as smart cameras, wearable services are conveniently accessible, and disaster devices, etc., online, hence generating massive recovery is more efficient. A large number of devices amounts of data that can submerge storage are located at the edge of the network and require systems. The Cloud computing paradigm is support for mobility, low latency, real-time, and unable to meet these requirements, particularly location-aware services [Rajk17]. New computational in some critical applications (as health paradigms, termed as Fog computing, edge computing monitoring, emergency response, etc.) that and Mobile Cloud computing, that subdue the require low latency, and delay caused by shortcomings of cloud computing by transferring some transferring data to the cloud and then back to of the core functions of cloud towards the network the application can seriously impact their edge, have emerged. Hence, the cloud computing performances. To overcome this limitation, paradigm is unable to meet certain requirements such Edge paradigms, as Fog computing, Edge as: the low latency and jitter, the context awareness, the computing and Mobile Cloud computing, have mobility support, etc. However, these requirements are been proposed, where cloud services are crucial for several current applications (e.g. vehicular extended to the edge of the network to networks, augmented reality). To fulfill these decrease the latency and network congestion. requirements, for instance, Edge computing, a This paper proposes a software architecture distributed computing paradigm has emerged in recent supporting the modelling of Edge computing years. It empowers the network devices at different dedicated systems. The current situation of hierarchical levels with various degrees of emerging Edge paradigms is analyzed in computational and storage capability, suitable for the detail. An approach based on software services and applications of IoT [Rod18]. component technology is proposed and Few research attempts are devoted to the modelling and applied using Fractal components model, development of Edge systems dealing with their main which can specify semantics of every- characteristics, as the bandwidth/response time trade- changing dynamic and distributed integration off in traditional cloud computing systems with of software components. Furthermore, a case heterogeneous types of computation tasks and wearable study of the patient monitoring system (PMS- mobile devices. EDGE) along with its application model and The main goal of this study is to holistically analyse the network topology is expounded. Edge computing architecture, a non-trivial extension of Keywords - Distributed Computing, Cloud cloud computing [Sark16], which serves as a platform computing, Edge computing, Component Model, that bridges numerous sensing devices, situated at the Fractal, FractalAD, Patient Monitoring System. network edge, to the core computing structure of the cloud. Then, we propose a generic software 1. Introduction architecture supporting the most features of these systems. Our approach is driven by the Component- Recently, Cloud computing, has added a new Oriented Software Development (COSD) [Hazl11] that dimension to the traditional means of computation, data has been recognized as a viable way of building storage, and service provisioning [Rajk17]. Indeed, the software systems. Although there are many different rapid increase in the number of ubiquitous mobile and views on what a component is and what its features are, Copyright © by the paper’s authors. Copying permitted only for private common consensus regards a component as a black-box and academic purposes. entity with well-defined interfaces and behavior, and In: Proceedings of the 3rd Edition of the International Conference on emphasizes, as one of the key features, its reusability in Advanced Aspects of Software Engineering (ICAASE18), Constantine, different contexts. Algeria, 1,2-December-2018, published at http://ceur-ws.org Page 98 A Component-based Modeling of Edge Systems Computing ICAASE'2018 Our contribution in this paper is based primarily on cloud computing. Indeed, the Cisco Internet Group these strengths of COSD while considering software Business Solutions predicts that by 2020 there will be Edge systems as a composition of some hierarchical nearly 50 billion objects connected, some applications components, viewed as gray-box/glass-box entities with of IoT must have a very short response time, others the internal structure visible as a set of communicating may contain private data, and others may generate a subcomponents. We present a realization of the very large mass of data, something that will produce a proposed model for Edge computing systems by big load on the network. exploiting the component model Fractal [Hazl11]. Thus, the large distance between the user and the cloud Thus, a component Fractal is used as a software Edge as well as the massive amount of data received by the element, conforming to its component model and being user from IoT objects causes an increase in latency and independently deployed and composed without bandwidth, which will have a negative influence on the modification according to a composition standard response time of some crucial applications, as for [Coup06]. Besides, Fractal components are reflective, instance those related to human health. Therefore, the in the sense that their execution and their internal need for new Edge computational paradigms to support structure can be made explicit and controlled through the requirements of these latency-sensitive IoT well-defined interfaces. These reflective capabilities, applications is in the offing. Fog computing, Edge however, are not fixed in the model but can be computing and Mobile Cloud computing, have been extended and adapted to fit the programmer’s proposed to subdue the shortcomings of cloud constraints and objectives. computing by transferring some of the core functions of cloud towards the network edge. We notice that all The remaining of the paper is organized as follows. these technologies may complement the Cloud ones by Section 2 provides a comprehensive outline of the Edge serving the requirements of the real-time, low-latency computing architecture and analyses the performance of IoT applications running at the network edge [Sark16], this paradigm in contrast with that of the traditional and also supports complex analysis and long-term cloud computing framework. In Section 3, the storage of data at the core of the network. Each of these architectural modelling of the Edge computing technologies has functions that characterize it and offer dedicated system is presented. We design the different a typical solution to the above problems. software components using FRACTAL model. The The common denominator in these edge paradigms is applicability and execution of our proposed model is the deployment of cloud computing-like capabilities at demonstrated in Section 4 through a realistic case the edge of the network. In this work context, we are study, the Patient Monitoring System “PMS-EDGE” interested in the Edge computing paradigm; we study before finally concluding the work in Section 5. through this section its main functions while explaining its platform. 2. EDGE COMPUTING: Principles and 2.1 Edge Computing Platform Definition Edge Computing is an open distributed computing architecture; it's a convenient optimization method used Cloud Computing has emerged as a new technology in the cloud, pushing intelligence towards the periphery and an infrastructure in which storage and computing of the network allowing treatments to be close to the power are managed by remote servers to which users latter [Weis16]. connect via a secure internet connection. This practice permits to express a decentralized data Nowadays, it becomes one of the most famous word processing power, these are processed by the device that it is used by virtually all modern businesses. This itself without having to transmit them to a data center trend is also used to market many types of software and (cloud) which makes it possible to optimize the network services facilitating further our daily life. network infrastructure, reduce operating expenses and Cloud computing, in general, has added a new ensure a high level of flexibility at the level of IT dimension to the computation technology, including the services. Figure 1 illustrates this principle and shows data storage and the service provisioning. the three main layers of an Edge computing However, the proliferation of connected objects (IoT) architecture. takes a way of a fairly large growth over time and questions the traditional network architecture of the International Conference on Advanced Aspects of Software Engineering Page 99 ICAASE, December, 01-02, 2018 A Component-based Modeling of Edge Systems Computing ICAASE'2018 the distance to Browse. This reduces the transmission costs, the latency of shrink and improve the quality of service; • Edge Computing equipment: represent a wide range of existing and new equipment used in Edge Computing. Many devices and peripherals edge are provided by CISCO and other hardware vendors; • Mobile Edge Computing: offers IT service environment at the edge of the mobile network. This is characterized by ultra-low latency and high bandwidth as well as 5G scenarios. Figure 1: Edge Computing principle The Edge Computing Platform Layer mainly provides 2.2 Motivation mini data centers at the edge of the network, where the devices of the IoT are connected. This will make it The Edge Computing is implemented to improve the possible faster processing (low latency), as shown in performance of the Cloud Computing by bringing Figure 1, due to the short distance between the Edge several interests which can be summed up in the Computing layer and the IoT devices (unlike the cloud, following points [Hped17]: where data centers can be very far from the devices). • It allows to perform analyses, calculations on We clarify some key words used by this paradigm and collected data from different IoT devices closer to whose definition will serve later to draw our the source of their generation (on the edge). This architecture. will lead us to efficient and latency less data • Edge: means the edge that differs from one use case processing; to another, in an automotive scenario, the edge • It ensures data security by moving security elements could be a car, in the making, it could be a machine closest to the original source of the attack; in a workshop, and in the computer, the edge could be a laptop, etc.; • It allows applications and smart devices to be used effectively in separate locations, and respond to • Edge Gateway: represents the buffer between edge data almost instantly; computing and the wider fog network. It is at the latter level that the altering and processing of the • It also provides new capabilities in IoT hundreds of thousands of data generated by the applications. Namely, object detection, facial sensors is performed to increase efficiency by recognition, obstacle avoidance. These benefits decreasing bandwidth and latency; reduce response time, energy consumption, etc. [Saty17]. • Edge Servers: a set of computers placed in warehouses, distribution centers or factories that run the applications located near the network, they 3. FRACTAL4EDGE: A COMPONENT manage the incoming and outgoing internet mail BASED MODEL FOR EDGE flow; SYSTEMS • Edge devices: represent any device, or machine In the scope of our modelling approach, we opted for that produces, collects or processes the data. This the use of component-based models to define the can encircle the sensors, controllers, smart devices, essential elements of the Edge Computing systems. such as smartphones, tablets, vehicles, computers as These abstract models have a simple hierarchical nature well as routers and servers; which allows the mastery of their complexity. • Edge Application Services: they reduce volumes of data to be transmitted, the resulting traffic and 3.1 Our Approach Principle International Conference on Advanced Aspects of Software Engineering Page 100 ICAASE, December, 01-02, 2018 A Component-based Modeling of Edge Systems Computing ICAASE'2018 First, we give a generic layered architecture for Edge computing systems allowing a separation of concerns mastering thus their complexity. Then, this architecture constitutes an intermediate model for the formal one. This latter is based on Fractal components model, allowing specifying either structure or behaviour of these systems. Indeed, the separation of components of the Edge computing systems by adopting this architecture, called LAyered Edge architecture, ensures a simple and understandable crossing to the formal model that serves to analysis and execution purposes. Traditional non-formal design methods generally fail to meet all the requirements of the Edge paradigm. The main problem is that they usually result in incoherent perspectives and ambiguous representation. The method we propose aims to give a unified way to Figure 2: LAEdge Architecture describe systems so as to result in a deterministic, understandable model. In addition, it should be possible • The Iot Devices Layer: It brings together four to 1/ (Specialization): divide into several sub-groups layers (sensors, controllers, hybrid devices and the development team of Edge computing system. Each users). The sensors are supposed to retrieve data, one focuses on the development of a precise and the controllers are supposed to process and component; 2/ (Update easiness) update a component manipulate these data. As for hybrid devices, they without requiring a complete recompilation of the hole are seen as consumers and data producers at the model; 3/ (Choice of development languages) develop same time. However, users represent a source / related software components with different interceptor of information. The connection between programming languages; 4/ (Reusability) use existing these sub layers and the upper layer (the Edge layer) software components to create new software; 5/ is made through an under layer (layer connectors). (Extensibility) extend a given Edge system by adding The latter brings together a set of connection means new components. (Wi-Fi, Bluetooth, etc.), which enables the retrieved data to be transferred to the Edge layers where the appropriate treatments are made. 3.2 A Layered Architecture for Edge Computing Systems • The Edge Layer: It represents the platform of the Edge Computing; it is the main layer of our In this section, we give the definition of the basic architecture. It encompasses a set of peripherals, elements of our proposed LAyered Edge Computing including edge servers which handle data architecture (see Figure 2). Obviously, this architecture manipulation and management such as security, is divided in three main layers according to the Edge analysis, processing of data, etc. in the closest way computing principle (see Figure 1). possible to IoT devices. This layer also encapsulates edge getaways such as: routers, switches, servers, etc., which in turn represent a connection point between the edge nodes and the set of IoT devices. This makes it possible to manage the network, in addition to validating, storing, processing and filtering hundreds of thousands of data on time before sending them to a data centre (cloud). When the appropriate treatments are completed, the resulting data are communicated to the upper layer (cloud layer) through an edge International Conference on Advanced Aspects of Software Engineering Page 101 ICAASE, December, 01-02, 2018 A Component-based Modeling of Edge Systems Computing ICAASE'2018 gateway server and by means of a sub-layer "the “C-CPT” “iot” communication protocol-layer", (http for example). Controllers Primitive Required Link component interfaces controller • The Cloud Layer: It represents a space of storage, “C-CTRL” “edge” or “BC” analysis and data processing, coming from the “cloud” lower layer (the Edge layer), by means of Provided communication protocols. Hence, these data can be interface accessible at any time and from anywhere. “iot” Users Primitive Required Link 3.3 Software Elements of FRACTAL4EDGE Model component interfaces controller “C-User” “edge” or “BC” We propose a comprehensive and a generic formal “cloud” Provided model for Edge Computing systems, reducing their interface complexity and design, using Fractal components “iot” model. Our Fractal4edge model gives a precise Edge Gateway Primitive Required Link semantics to architectural elements of these systems component interface controller and possible interactions that govern their complex “C-Edge- “iot” “BC” behavior. Especially, all the advantages of Fractal GT” Provided components model are inherited by applying our interfaces process of developing such systems. Thus, we have “gt1”, “gt2” defined some matching rules that allow associating a “gt3”, “gt4” clear semantics to the various Edge Computing Edge Node Composite Required Link concepts identified in the LAEdge architecture. The component interfaces controller following table summarizes a set of these rules. “C- “gt1”, “gt2” “BC” and Edge_Node “gt3”, “gt4” “CC” ” Provided Table 1: Fractal for LAedge interfaces “ne1” or Architectural Fractal Fractal Fractal “ne2” element in Component interfaces controller Server Edge Primitive Required Link LAEdge Gateway component interfaces controller Iot Layer Composite Required Link “C-SV- “ne1” or “BC” component interfaces controller Edge-GT” “ne2” “C-Iot” “edge” and “BC” and Provided “cloud” “CC” interface Provided “edge” interface “iot” The above mapping table is important because aims to Edge Layer Composite Required Link represent the proposed architecture model based on the component interface controller three FRACTAL main concepts: ‘’Fractal “C-Edge” “iot” “BC” and Component’’, ‘’Fractal interfaces’’ and ‘’Fractal Provided “CC” and controller’’. At this level of abstraction, the semantics interface “LC” of ‘’IoT Layer’’ ‘’Edge Layer’’ and ‘’Edge Node’’, is “edge” realized by composite components, while ‘’Cloud Cloud Layer Primitive Required Link Layer’’, ‘’Sensors’’, ‘’Controllers’’, ‘’Users’’, ‘’Edge component interface controller Gateway’’ and ‘’Server Edge Gateway’’, are just “C-Cloud” “edge” “BC” and Provided “CC” and primitive components. We have opted for the interface “LC” FRACTAL component model, it is an extensible and “cloud” reflexive model which has a simple hierarchical nature, Sensors Primitive Provided and which is independent from any programming component interface language. Additionally, FRACTAL offers a clear International Conference on Advanced Aspects of Software Engineering Page 102 ICAASE, December, 01-02, 2018 A Component-based Modeling of Edge Systems Computing ICAASE'2018 separation between the functional and non-functional intervention devices (controllers) or outright to doctors needs of a given application, with a great modularity and nurses for performing necessary treatments. The and possibility of extended extensions, as well as a floor plan and overview of the “PMS-EDGE” solution persistence management of data through its API, which is shown in Figure 3. perfectly suits our case study. 4. CASE STUDY: PMS-EDGE In the last few years, healthcare applications based on Internet of Things (IoT) have been receiving increasing attention because they provide a seamless platform to millions of people to facilitate ubiquitous health monitoring of patients [Jong18]. These applications are challenging the existing healthcare systems (PMS) and make them increasingly difficult to manage. The PMS (Patient Monitoring System) is a system for monitoring the health of patients. It combines hardware and software devices to protect and monitor patient health in real time using a set of sensors, controllers and medical intervention devices. These allow the collection of primary vital signs which are standard in Figure 3: PMS-EDGE solution most medical settings [Shen18]: Body temperature, Heart rate or Pulse, Respiratory rate and Blood 4.2 PMS-EDGE Fractal model pressure. The medical and healthcare industry in the context of The proposed methodology is described in Figure 4. It functions, operations, and applications can be divided shows the general structure of our case study and into three areas [Fara18]: (i) large healthcare illustrates the different components (fractal) and their organizations such as hospitals, (ii) small clinics and connection through communications interfaces dispensaries, and (iii) non-clinical environments such (provided in red, and required in green). It also shows patients’ homes. The following case study “PMS- the set of controllers that allow the management and EDGE” provides an effective solution on how data can execution of components, and ensure their assembly. be collected through sensors and provided in terms of the patient’s vital signs, in small clinics. We will take the potentials areas where IoT and Edge computing could play an instrumental role, and we will discuss applicability of our proposal “FRACTAL4EDGE” by considering this case study. The aim of the “PMS- EDGE” case study is to improve response time by delegating the data-processing authority to a local edge node. 4.1 System architecture The proposed "PMS-EDGE" consists of a smart clinic solution that is set up with medical sensors, a patient subject with mobile devices such as smartphone. The sensor data (patient’s vital signs) are transmitted using Figure 4: PMS-EDGE architecture a smart gateway to an Edge node (located near the network) where pre-processing algorithms are The architecture model “FRACTAL4EDGE” for our implemented. The processed data with contextual case study “PMS-EDGE” consists of fifteen information is finally transmitted to medical components, thirteen of them are primitive while only two are composite. Table 2 summarizes the main International Conference on Advanced Aspects of Software Engineering Page 103 ICAASE, December, 01-02, 2018 A Component-based Modeling of Edge Systems Computing ICAASE'2018 elements of the “PMS-EDGE” and their corresponding Primitive required interface ones in the proposed methodology component ” tmp, gly and t ” “FRACTAL4EDGE”. “smartwatch” provided / Thanks to the model proposed for edge computing interface '' systems 'Fractal4Edge', we could instantiate it and restmp, resgly apply it to represent the model of our case study (PMS- and restn '' EDGE) in the form of fractal components. This solution has made us easier modelling task of our PMS system through a set of fractal components drawn from the Primitives provided -link controller Fractal4Edge model and which results in the Table 2. components interface” rx ” "BC" “Routers” required interface '' restmp, resgly Table 2: FRACTAL4EDGE PMS and restn '' Primitives provided -link controller Components Fractal Fractal components interface” ctrl” "BC" Interfaces Controllers “Smart- required interface Composite provided -link controller gateway” ''rx'' component interface “r” “BC” “central edge implementing -content controller 4.3 Execution and Evaluation node” java.lang.Runnab "CC" le -life cycle In order to carry out an evaluation of the proposed controller ''LC '' methodology, an implementation consists of a judicious coupling between FRACTAL API as a high-level Primitives required link controller component-based language, and FRACTAL ADL for components interface” ctrl” "BC" parsing XML-based specifications of the proposed “primary vital provided signs interface “ctx” PMS-EDGE solution. Figure 5 gives a broad outline of controllers” the defined components and their dependencies Primitive required link controller according to the proposed “LAEdge” architecture in component interfaces “ctrl” "BC" section 3.1. “doctor” and “md” Primitive provided link controller component interfaces “ctx” "BC" “Patient” and “md” required interface” r” Composite provided -link controller component interfaces “ctrl” "BC" “local edge required -content controller node” interface” r” "CC" Primitives required components interface” ctrl” / “primary vital provided signs sensors” interface '' tmp, Figure 5: PMS-EDGE Implementation gly and tn '' To illustrate the execution of our case study “PMS- EDGE”, we suggest two scenarios of collecting data through sensors and providing it in terms of the patient’s vital signs; the first is a cloud computing- based solution, and the second consists of our proposed solution. For this purpose, we evaluate the patient's International Conference on Advanced Aspects of Software Engineering Page 104 ICAASE, December, 01-02, 2018 A Component-based Modeling of Edge Systems Computing ICAASE'2018 condition through three vital signs: Body Temperature based on software component technology (BT), Blood Glucose (BG) and Blood Pressure (BP). “FRACTAL4EDGE” is proposed and associated to the For a given value of BT= 40; BG=1.7 and BP= 19.90, proposed software architecture “LAEdge”; supporting the simulation results using the two scenarios (cloud- the modelling of Edge computing dedicated systems. based solution and our proposed solution) are shown in This allows the designer to separately specify the the figure 6 and figure 7 respectively. The Figures (6 semantics of each layer using a FRACTAL component and 7) help to explain the simulation result by model, which can specify every-changing dynamic and displaying the response time for medical relevant distributed integration of software architecture treatments. elements. Furthermore, a case study of the patient monitoring system “PMS-EDGE” along with its application model and Edge-based network topology is expounded. It aims is to improve response time and gives the opportunity to save lives. As future work, we plan to exploit meta-modelling and model transformation tools to conceive a graphical interface and a “FRACTAL4EDGE” specification generator in order to facilitate the exploitation of our proposed approach, thereby permitting graphical Figure 6: Simulation result for Cloud-based editing and automatic generation of the corresponding solution specifications. References [Sark16] Subhadeep Sarkar, Sudip Misra, Theoretical modelling of fog computing: a green computing paradigm to support IoT applications, IET Netw, 2016, Vol. 5, Iss. 2, pp. 23–29 & The Institution of Engineering and Technology 2016, ISSN 2047-4954. Figure 7: Simulation result for PMS-EDGE [Rod18] Rodrigo Roman, Javier Lopez, Masahiro solution Mambo, "Mobile edge computing, Fog et al.: A survey and analysis of security threats and Lastly, again according to the simulation result of challenges", Future Generation Computer figures 6 and 7, we conclude that the data is processed Systems, Volume 78, Part 2, January 2018, Pages on a cloud-based solution whose response time is more 680-698, Elsevier. than “1 minute”, while on the proposed solution (PMS- EDGE), the response time is improved; less than “18 seconds”. This early response time will save countless [Rajk17] Harshit Gupta, Amir Vahid Dastjerdi, lives. Soumya K. Ghoshy, and Rajkumar Buyya, "iFogSim: A Toolkit for Modeling and Simulation of Resource Management Techniques in internet of Things, Edge and Fog Computing 5. CONCLUSION Environments", Component-Oriented Software Development (COSD) Journal of Software: Practice and Experience, have been adopted as a methodology foundation in the Volume47, Issue 9, Special Issue: Cloud and Fog Edge computing paradigm for their main characteristics Computing, September 2017, Pages 1275-1296. of modularity and cohesivity. In that way, an approach International Conference on Advanced Aspects of Software Engineering Page 105 ICAASE, December, 01-02, 2018 A Component-based Modeling of Edge Systems Computing ICAASE'2018 [Hazl11] Hazleen Aris and Siti Salim, "State of Component Models Usage: Justifying the Need for a Component Model Selection Framework", The International Arab Journal of Information Technology, Vol. 8, No. 3, July 2011. [Coup06] Eric Bruneton, Thierry Coupaye, Matthieu Leclercq, Vivien Quéma R. Nicole, Jean Bernard Stefani, "The FRACTAL component model and its support in Java", First published: 17 August 2006, https://doi.org/10.1002/spe.767. [Weis16] Weisong Shi, Jie Cao, Quan Zhang, Youhuizi Li, and Lanyu Xu. Edge computing : Vision and challenges. IEEE Internet of Things Journal, 2016. [Hped17] Hewlett Packard Entreprise Development LP. What is edge computing. Technical report, HPED, 2017. [Saty17] Mahadev Satyanarayanan, The emergence of edge computing. Journal of Computer, 2017. [Shen18] Minh Pham, Yehenew Mengistu, Ha Do, Weihua Sheng. Delivering home healthcare through a Cloud-based Smart Home Environment (CoSHE). Future Generation Computer Systems, 2018. Elsevier. [Jong18] Min Woo Woo, JongWhi Lee, KeeHyun Park. A reliable IoT system for Personal Healthcare Devices, Future Generation Computer Systems, 2018. Elsevier. [Fara18] Bahar Farahani, Farshad Firouzi, Victor Chang, Mustafa Badaroglu, Nicholas Constant, Kunal Mankodiya, Towards fog-driven IoT eHealth: Promises and challenges of IoT in medicine and healthcare, Future Generation Computer Systems, 2018. Elsevier. International Conference on Advanced Aspects of Software Engineering Page 106 ICAASE, December, 01-02, 2018