BRAIN-IoT: Model-based Framework for the Development, Deployment and Management of Distributed IoT Applications
IoT applications are composed of a highly heterogeneous interconnection of distributed platforms and devices offering a wide diversity of capabilities. BRAIN-IoT focuses on the realization of a framework and methodologies for fast and safe implementation of intelligent IoT applications leveraging on Component-Based Development and Event-Driven dynamic deployment techniques, similar to Function-as-a-Service (FaaS) paradigm. The objective is to provide a software engineering approach, which enables the advanced exploitation of the full range of diversity in Smart City and Industry 4.0 environments. Such environments promise to be orders of magnitude more sophisticated than traditional Enterprise ones. They will be massively distributed, heterogeneous, federated, and co-evolving software ecosystems: adapting, changing, and scaling in response to local requirements and environmental changes. For such software ecosystems to be economically sustainable, operational simplicity, maintainability, and runtime adaptive must be intrinsic to their architectures; for this reason, these non-functional requirements are basic objectives for the development of a solution in this field. BRAIN-IoT allows the design of IoT applications composing and orchestrating existing IoT Platforms. Components orchestration is implemented via modeling, code-generation and deployment of relevant software artifacts, which implements Smart Behaviors and Adaptation Layers, both in a static and Event-Driven way. BRAIN-IoT implements its core capabilities leveraging and extending different ECLIPSE tools such as Papyrus and SensiNact.
The next generation of Smart City and Industry 4.0 applications will be geographically distributed, heterogeneous, co-evolving software ecosystems, significantly more sophisticated than the current Enterprise or Cloud compute environments. To be economically sustainable and achieve solution longevity, these software ecosystems must be operationally simple, cost-effective to maintain over extended periods of time, and able to adapt to both changing environmental conditions and service requirements in a cost-effective way.
Software Systems continue to be built for fixed unchanging production environments with pre-determined functional behaviours. The issues of operational complexity, maintainability, and economic sustainability tend to be ignored. Planned functional changes, or changes forced by the underlying runtime environment, are still treated as exception behaviours. Attempts to increase agility are then pursued by a DevOps model: this results in increasingly tight-coupling between the production environment and the source development teams. While this is manageable for enterprise and centralized cloud environments, which, to varying degrees of success, enforce homogeneous Information Technology (IT) environments, the approach fails in highly heterogeneous and evolving ecosystems of inter-related software services.
Smart City and Industry 4.0 environments promise to be orders of magnitude more sophisticated than traditional Enterprise environments. Such environments will be massively distributed, heterogeneous, federated, and co-evolving software ecosystems: adapting, changing, and scaling in response to local requirements and environmental changes. For such software ecosystems to be economically sustainable, operational simplicity, maintainability, and runtime adaptivity must be intrinsic to their architectures; for this reason, these non-functional requirements are basic objectives for the development of a solution in this field.
The BRAIN-IoT Solution
A BRAIN-IoT Federation is a geographically distributed entity composed of two or more BRAIN-IoT Fabrics; a BRAIN-IoT Fabric is a data-center centralized structure composed of one or more Fibres (each an OSGi framework); a Fibre may dynamically assemble composite OSGi functions or services, or where required, act as a local management agent controlling traditional applications deployed as container images. BRAIN-IoT Fabrics are self-contained entities with relocatable management services, which provide device discovery, search, composition and orchestration, allowing the rapid deployment of applications. Each BRAIN-IoT Fabric is able to dynamically deploy Smart Behaviours to appropriate resource within the environment in response to environmental triggers. The approach taken is conceptually similar to compute Lambdas made popular by Amazon Web Services (AWS); but more sophisticated in that the required behaviours are dynamically installed at the most appropriate points within a highly heterogeneous environment. The BRAIN-IoT federation achieves this by leveraging the Requirements and Capabilities metadata provided by default by all OSGi Bundles. To create Smart Behaviours, BRAIN-IoT framework includes model-based tooling that is compliant with Internet of Things Architecture (IoT-A) and optionally, via the use of Behavior, Interaction, and Priority (BIP) allows verifiability of runtime behaviours. The solution presented is part of the BRAIN-IoT framework that aims to support smart autonomous and cooperative behaviours across populations of heterogeneous Internet of Things (IoT) entities; an example of which may be heterogeneous agent-based CPS. For this population of entities, BRAIN-IoT also includes mechanisms to enforce privacy and data ownership; and uses open semantic models to enable inter-operable operations and exchange of data and control features between members. A primary requirement of BRAIN-IoT is to accommodate environmental and functional: i.e., environmentally triggered adaptations, where a new physical device/entity is encountered, which must be managed/interacted with; self-repair /re-optimization, where unforeseen failures occur within the environment or more appropriate resources are made available; adaptation to environment requests, spanning from simple cases, like scaling in response to load, to sophisticated behaviours. Smart Behaviours address these requirements. Each BRAIN-IoT Fabric is able to dynamically deploy them to appropriate resource within the environment in response to environmental triggers. If the required behaviours do not exist in either the runtime or the Smart Behaviour repository, then they may be rapidly created via the BRAIN-IoT modelling process. Sophisticated aggregate behaviours can be achieved via chaining together simpler behaviours: these behavioural chains are automatically assembled by each BRAIN-IoT Fabric. From a Complex Adaptive System (CAS) perspective, the approach pursued can also be thought of as analogues to a simple Urn Model example: the Smart Behaviours Bundle Requirements/Capabilities metadata represents the Boundary, while the Smart Behaviours Events represent the corresponding Signals.
BRAIN-IoT Fabric is comprised of the following three structural layers.
Physical: The set of physical computing resources within the physical environment to be managed (e.g.,Linux Servers and Robot Operating System (ROS) Robots). Physical resources may be introduced into, or removed from the environment at any point.
Fabric: To create a Fabric, a set of OSGi/Java agents and infrastructure services are installed upon this physical layer, which provide BRAIN-IoT's consensus, discovery, system provisioning, and communication services.
Systems: A System is a distributed entity composed of a set of interrelated software components. One or more systems may be deployed to a Fabric. In response to an Operator Command or an Environmental Trigger, the BMS component is responsible for selecting the most appropriate Smart Behaviour from the BRAIN-IoT Marketplace, selecting the most appropriate BRAIN-IoT node/s. Also, each System may include System Parts for functional components that are known in advance to be needed in the target environment: i.e., for physical device integration BRAIN-IoT Edge nodes require sensiNact gateways.
Smart Behaviours: Smart Behaviours define the final structural layer of a BRAIN-IoT environment. In response to environmental triggers, each BRAIN-IoT System is capable of dynamically deploying sets of interrelated Smart Behaviours. These Smart Behaviours may be generic in nature or specific to a particular runtime environment and use-case. BRAIN-IoT provides a model-based framework for the modeling and creating of dependable sensing and actuation in intelligent decentralized IoT systems; which are referred to as 'Smart Behaviours'. The resultant software artifacts may be released into a BRAIN-IoT Marketplace and made available to one or more BRAIN-IoT Fabrics. In addition to Smart Behaviours, the BRAIN-IoT modelling environment may also create required System Descriptions with appropriate system parts. As shown in Figure 1, one or more Fabric(s) may import specified Systems from the BRAIN-IoT Marketplace:
- Different Fabrics may import the same System: i.e., System 1 is imported to Fabric 1 and Fabric n.
- A Fabric may host multiple Systems: i.e., Fabric n imports System 3 and System 1.
In contrast to the current Agile Continuous integration/Continuous delivery (CI/CD) Industry practices of pushing developer changes as rapidly as possibly into Production, the BRAIN-IoT Marketplace provides essential decoupling between the development and the runtime. Developed artifacts are pushed to the repository, then pulled from the repository as and when required by each BRAIN-IoT Fabric.
Figure 1: Relationship between Modeling Tool, Marketplace and Runtime Infrastructure
BRAIN-IoT solution is tested and evaluated in two futuristic scenarios, namely Service Robotics and Critical Infrastructure Management.
The Service Robotics use case will involve several robotic platforms, like the open-source Robotics Operating System (ROS), which need to collaborate to scan a given warehouse and to assist humans in a logistics domain. The term Service Robotics is generally related to the use of robots to support operations done by humans and the logistics domain is one of the more interesting, for the presence of several tasks, where the robots can help the workers, making their tasks easier and safer. For example, they can cooperate to move a heavy object from one place to another. At the same time, robots involved in the scenario should scan the whole warehouse and update in real-time informative interfaces for the managers and the workers (e.g. warehouse's map), sharing the collected information. In addition to the information related to the maps of the whole monitored area, the connected robots will also be equipped with a set of sensors, which will allow collecting interesting information, like room temperature, presence of humans or presence of obstacles in the robot-path. Since several robots collaborate to collect the information, they can keep the status of the area updated in real-time and balance the effort required among them. In the beginning, the robots are configured with some default information, like the map of the warehouse. Then, this information is updated in real-time, while the robots perform their main tasks. The demonstration use case proposed will include both real-time collection of data and control of the included robots. Particularly, the actuation of these robots will be an interesting test-bed for the platform, to demonstrate how the solutions developed by BRAIN-IoT allow to control remotely, in a standard way, the complex devices involved in this scenario.
Critical Infrastructure Management
The Critical Water Infrastructure Monitoring and Control use case focuses on the management of the water urban cycle in metropolitan environment of Coruna. The base of this system will be made of a complex portfolio of probes, meters, sensors, devices, and open-data sources deployed on the field, including water, flow, and pressure meters on the water mains; smart devices, which measure the main chemical-physical characteristics of water; pluviometers, which can monitor the level of rainwater in a specific zone; water circular pumps, which can be used to control the flow of liquids in heating systems. These devices will be geographically distributed, heterogeneous and will be provided by different owners: directly by the water utility, by end-users themselves or by third-party service providers, like, SMEs providing ancillary water services. For this reason, there will be different data involved in these scenarios: meteorological open data, reservoir water level data, purification data, distribution data in the various subsystems, customer data in urban water supply processes, sewage collection and sewage treatment data in different subsystems. The collection of all this data will allow to provide value-added services, like showing to the client, commercial or not, the quality of the water provided to them or the possibility to react quickly to critical situation and to do predictive maintenance, through the ability to detect anomalous behaviours and to fix them before they become an issue difficult to be fixed. The BRAIN-IOT solution will enable this scenario, allowing to collect data from all the different domains and to actuate the devices where needed. The WOT-based approach used for the design of the platform will be leveraged to collect the data, provided by different IoT platforms, using heterogeneous protocols and data formats. Specifically, the use case will involve SICA-EMALCSA platform, SOFIA2 platform, MACRAUT platform, AGATA platform and other private platforms. Furthermore, BRAIN-IOT will focus particularly on designing and developing ways to control devices abstracted by these solutions.
The symptoms caused by system complexity are increasingly encountered and understood in the context of both Industry 4.0, and for Smart City projects. Operational complexity is rapidly becoming an operational roadblock. To meet the environmental, social and economic potential promised by Smart City and Industry 4.0, this issue must be addressed: tomorrow's sophisticated software ecosystems must be dramatically simpler to manage, maintain, adapt, and evolve. To achieve this objective, the IT industry must look towards the science of Complex Adaptive Systems for guidance. This paper presents BRAIN-IoT consortium's attempts to pursue this engineering philosophy. By leveraging existing open Industry Standards for modularity (OSGi), the BRAIN-IoT delivers a software ecosystem capable of deploying/assembling, orchestrating, and managing sophisticated IoT applications. Conceptually, it is similar to, but significantly more flexible than compute lambdas; BRAIN-IoT demonstrates how sophisticated distributed behavioural pipelines of software components can be dynamically assembled, in response to environmental triggers. Meanwhile, by pursuing a modular structural hierarchy (i.e., an holonic approach), BRAIN-IoT enables the natural creation of federated distributed environments ideally suited to the demands of both Smart Cities and Industry 4.0. The BRAIN-IoT project demonstrates how these concepts can be applied to a variety of real-world scenarios to create high-value services: the chosen use cases demonstrating the flexibility of the BRAIN-IoT approach within a diverse set of operational environments. The Robotics warehouse use case demonstrates BRAIN-IoT's use in highly automated, dynamic, and adaptive manufacturing environments. In contrast, the second use case concerns the monitoring and control of public water management infrastructure for the city of Coruna and demonstrates the use of BRAIN-IoT in mission-critical human-in-the-loop Operational environments. Operational simplicity and robustness remain paramount considerations. Hence, in addition to developing the functional elements required to deliver the target Use Cases, BRAIN-IoT will continue to escalate the severity of cascading failure events and test BRAIN-IoT's mean-time-to-recovery abilities.
- BRAIN-IoT Edge Nodes are based on ECLIPSE SensiNact - https://projects.eclipse.org/projects/technology.sensinact
- BRAIN-IoT Modeling Framework is based on ECLIPSE Papyrus - https://projects.eclipse.org/projects/modeling.mdt.papyrus
- BRAIN-IoT Fabric is based on https://paremus.com/products/#psf