A Resource Oriented Modeling Approach for the Internet of Things: A Business Process Perspective Yongyang Cheng, Shuai Zhao, Bo Cheng, Junliang Chen State Key Laboratory of Networking and Switching Technology Beijing University of Posts and Telecommunications Beijing, China zhuifeng@bupt.edu.cn, zhaoshuaiby@bupt.edu.cn Abstract—Recently, the rapid development of Internet of 2.0 standard. It implies that without the proposed approach, Things (IoT) has attracted growing attention from both industry IoT devices could not be considered as potential executive and academia. It means that innumerable IoT resources could parties in the automatic resolution phase. Furthermore, most actively participate in the future internet and be able to flexibly perform considerable parts of traditional business processes. of the existing approaches only focus on the phase of creating However, most of the current work is in its infancy and focuses business process models and lack of the corresponding logic on technical implementation details, little attention is given to validation, which might cause serious logic problems during the mapping of business process resources from an IoT domain the business process execution phase. Finally, the modeling to a standard business process model. In this paper, we present a process is still a complicated and time-consuming issue for resource oriented modeling approach and integrate IoT paradigm on the business process layer to make it fit in the traditional developers. They need not only to focus on the mapping of business process environment. A running case of IoT-aware resources, but also to have an excellent programming skill business process application in the smart house is given to The main contributions of our work are as follows. validate our proposed approach. • We extend the graphic model and machine-readable Index Terms—Internet of Things, resource oriented modeling, BPMN 2.0, IoT devices model consisting of XML Schema Definition (XSD) specification of the business process metamodel of the I. I NTRODUCTION AND M OTIVATION notation BPMN 2.0, making it support the direct model- ing of IoT devices. IoT brings together real-world devices which have never • We design a Validator to provide support for detecting been connected before. That means that further integration whether there are logic errors of the pre-defined business of physical entities into internet applications will be a trend. process metamodel during the phase of modeling. Business Process Management (BPM) systems will benefit • We develop a UI-friendly Eclipse-based editor for devel- from the integration with IoT resources, if typical devices opers to manage the full lifecycle of the business process, such as RFID readers, sensors and actuators could directly take including graphic creation of process model, dynamic over responsibility as business process resources for individual definition of interaction interface, logical validation and business process tasks. As we know, the basis of the lifecycle execution. before any business process automation is the creation of a business process model. Furthermore, a model is composed II. R ELATED W ORK of many business process tasks. A business process task In this section, we compare our proposed resource-oriented corresponds to a special unit implemented by a service [1], [2]. modeling approach with other existing approaches. We will Therefore, from a business process perspective, this integration clearly point out the similarities and differences with their requires a special task which has the ability to interact with works. Yang Liu et.al. [5] propose a generic resource man- its physical environment through service interfaces. In order to agement model, which is composed of users, devices and build our work on a scientific foundation, we have investigated resources. Two cases are given to describe how users can most of the existing Business Process Notation (BPMN, BPEL obtain the logical information through this model. However, and JPDL) [3]. BPMN 2.0 not only supports the creation of a this model is human-oriented and the modeling is complicated graphic model, but also supports the generation of a machine- due to the lack of theoretical support for mapping physical readable model. Thus, BPMN 2.0 was evaluated as the most entities to standard business process resources. Sonja Meyer IoT-aware modeling standard [4] and will serve as the basis et.al. [6] present how the real-world services used for the for the mapping work of business process resources from an implementation of business processes differ from one another. IoT domain to a standard business process model in this paper. Although they extend BPMN 2.0 standard at the level of Although BPMN 2.0 standard could provide theoretical graphical and machine-readable model, this extension is based support for the modeling, challenges still remain to be solved. on the Lane. A Lane is a sub-partition within a process (often First of all, the role of IoT devices as a resource type of a within a pool) and is a coarse-grained process unit. Similar to business process could not be directly represented in BPMN them, we also extend BPMN 2.0 standard at these two levels. However, our extension is based on the Activity, which is a not directly visible as part of the graphic business process fine-grained unit and could directly inherit the model asso- model, but is included in the implementation and operation ciations of ResourceRole. Furthermore, they assign the IoT of attributes, as shown in Fig.1 (b). In addition, the extended resources at the time of process modeling. But we decouple the version of the service handler is shown in Fig.1 (c), which internal connection between IoT devices and services through could realize the attributes in a service definition file and be a special class Interface, which supports the assignment of used to further specify the ”Sensing Task”. IoT resources throughout the lifecycle of business process. Patrik Spiess et.al. [7] present an approach where BPEL B. Machine-readable Model processes are automatically partitioned and executed within the sensor network using lightweight node services among different engines. However, there might be many logic errors in the execution phase of the process, which should be checked out during the design phase. Thus, we design a Validator to detect logic errors of the pre-defined business process model. III. R ESOURCE O RIENTED M ODELING S PECIFICATION In this section, we propose a resource oriented modeling specification as an extension to BPMN 2.0 standard. When integrating IoT paradigm on the business process layer, we face two main challenges. First, the role of IoT device as a process resource could not be directly represented in BPMN 2.0 standard. Second, we have to deal with the IoT device and the service hosted on it at the same time. However, Fig. 2. The extension class of XSD specification of BPMN 2.0 standard BPMN 2.0 could not fully consider two types of resources on different levels concurrently in the same process metamodel. Besides the graphic model, we also extend the BPMN 2.0 To address these issues, we will extend BPMN 2.0 standard machine-readable model of the process to map IoT resources in both graphic model and machine-readable model. to the activity level while maintaining compatibility with the standard as much as possible. Although BPMN 2.0 standard al- A. Graphic Model ready supports the allocation of resources at the activity level, it could not directly reference the IoT-associated parameter for a resource role, which is not known in XML format to the BPM environment. To address this issue, we introduce a subclass to the Activity class and bring the resource allocation of devices directly to the activity level, compatible with the graphic model. The IoT Device class inherits the model asso- ciations and attributes of the Activity class. The OperationRef class supports the definition of IoT-associated parameters, which will pass over the generated XML document to the execution phase of the business process. In this case, an available IoT Device class could be found by the parameters at runtime. The IoT Service class defines the actual services that are hosted on the physical devices and exposes these services through the Interface class. Consequently, a process Fig. 1. The implementation and operation of Graphic Model. resource could be defined and mapped from an IoT domain to a machine-readable business process model, without being An Activity is an unit that is performed within a business known previously to the BPM environment. Fig. 2 shows the process and could directly inherit the model associations of XSD specification extensions. ResourceRole. In order to explicitly distinguish IoT devices from traditional business process performers and bind IoT C. Validator services to the graphic element through an interface compo- As mentioned above, we design a Validator to provide nent, we design a characteristic icon at the level of Activity. support for detecting whether there are logic errors of the Fig. 1 (a) illustrates a business process pool called ”IoT pre-defined business process metamodel during the phase of Business Process”, which contains a regular lane ”Lane” and process modeling. Validator has three function components: an IoT-aware lane ”IoT Device”. The task of ”IoT Device” converter, parser and analyzer. Converter first converts the is a ”Sensing Task”, which could expose its sensing service BPMN elements to the corresponding petri net modules, then through the restful interface. However, the sensing service is integrates these modules into Petri Net Markup language (PNML) file using the latest ISO/IEC 15909-2 International traditional BPM environment. In order to reach the goal, we Standard. Parser adjusts the layout of PNML file through initially extended the graphic and machine-readable model of Design Structure Matrix (DSM) and calculates the reachability BPMN 2.0 standard, making it support the direct modeling matrix. Based on the reachability matrix, Analyzer uses depth- of IoT-aware business process. Furthermore, we introduced first strategy to validate logic features (e.g. Loop, Deadlock, an auxiliary tool to detect logic errors of the IoT business Accessibility, etc.) of the pre-defined business process meta- model during the phase of process modeling. Finally, we model. Fig. 3 depicts the realization of Validator reference ar- tested our proposed approach practically by implementing chitecture. In order to better understand our work, we designed a prototype of an IoT-aware business process model in our a business process with a logic error due to the improper using extended UI-friendly Eclipse-based modeling tool. It is worth of gateways. A demonstrative video of Validator can be found mentioning that the work in this paper is a part of our entire at the following URL: https://youtu.be/T5HN0AboJ2A. project related to IoT-aware business process applications. More information about our work can be found in https: //youtu.be/Cw1tXlMMIUM. However, our work is still in its infancy and requires more actual applications to prove its applicability. Thus, we plan to leverage our proposed approach to implement advanced IoT- aware business process applications in a cloud environment. Fig. 3. The realization of Validator reference architecture ACKNOWLEDGMENT This work has been supported by National Natural IV. C ASE S TUDY Science Foundation of China ( Grant No. 61501048); In the previous section, we have introduced our approach of National-High tech R&D Program of China (863 Program) modeling IoT devices as process resources in the conventional (Grant No. 2013AA102301); The Fundamental Research BPM environment by extending the BPMN 2.0 standard. In Funds for the Central Universities (Grant No. 2017RC12); order to further illustrate the benefits of using our proposed China Postdoctoral Science Foundation funded project (Grant approach, we discuss an actual IoT-aware business process No.2016T90067, 2015M570060). example using our extended Eclipse-based modeling tool. R EFERENCES We design a business process of automatic curtain, showing the linkage mechanism between different devices in a smart [1] F. Leymann, D. Roller, and M.-T. Schmidt, “Web services and business process management,” IBM Systems Journal, vol. 41, pp. 198–211, house. The process includes two IoT devices: a light sensor 2010. providing the sensing service through a Restful-based interface [2] F. Yan, S. Liu,and Z. Yao, “Research on business process modeling and perceiving light intensity and a actuator providing the actuating business process service based on Web service,” In: 2nd Symposium on Web Society, l, pp. 254–257, 2010. service of opening or closing according to the measurement [3] P. Liu and B. Zhou, “Research on Workflow Patterns Based on jBPM of the sensor. Developers only need two steps to create this and jPDL,” In: 2008 IEEE Pacific-Asia Workshop on Computational IoT-aware business process: dragging graphic elements from Intelligence and Industrial Application, vol. 2, pp. 838–843. [4] Business Process Model And Notation (BPMN). OMG Specification. the element library and binding services to standard interfaces. Object Management Group 2011. Fig. 4 illustrates the corresponding graphic model in our IoT- [5] Y. Liu, Y. Tian, N. Kong, Y. Wang, S. Shen and W. Mao, “5.A User- aware business process modeling tool. Oriented Resource Management Model for the Internet of Things,”In: Advances in Wireless Sensor Networks. Communications in Computer and Information Science, vol. 334, pp. 313–324, 2012. [6] S. Meyer, A. Ruppen, and C. Magerkurth, “Internet of Things-Aware Process Modeling: Integrating IoT Devices as Business Process Re- sources,” In: International Conference on Advanced Information Systems Engineering, pp. 84-98, 2013. [7] P. Spiess, H. Juetting and H. Vogt,‘Integrating sensor networks with business processes,” In Real-World Sensor Networks Workshop at ACM MobiSys, pp. 139-152. 2010. Fig. 4. Dynamic opening or closing business process of a smart curtain V. C ONCLUSION AND F UTURE W ORK In this paper, we presented a resource oriented modeling approach for the Internet of Things to make IoT fit in the