UML Profile for Messaging Patterns in Service-Oriented Architecture, Microservices, and Internet of Things
Abstract
:1. Introduction
2. Related Work
3. UML Profile for Messaging Patterns
3.1. Stereotypes for Academic Patterns
3.2. Stereotypes for Enterprise Integration Patterns
- MessageChannel—the source application adds the information to a particular message channel and the target application retrieves the information from that channel;
- Message—data must be converted into one or more messages and then sent through messaging channels;
- PipesAndFilters—divides a larger processing task into a sequence of processing steps (Filters) that are connected by channels (Pipes);
- MessageRouter—receives a Message from the Message Channel and sends it to one of the alternative channels due to conditions fulfillment;
- MessageTranslator—translates one data format into another;
- MessageEndpoint—a client of the messaging system that can be used to send or receive messages.
- PublishSubscribeChannel—one input channel splits into multiple output channels. When an event occurs, a copy of the message is delivered to each of the subscribers’ channels;
- ChannelAdapter—operates as a messaging client to the messaging system and invokes functions via an application programming interface;
- RequestReply—sends a pair of messages, one to the target application and the second back to the source application, in separate channels;
- Saga—provides a way to define a series of related actions in a route that should be either completed successfully or not executed;
- DurableSubscriber—makes the messaging system save published messages while the subscriber is disconnected;
- EnvelopeWrapper—wraps application data inside an envelope that is compliant with the messaging infrastructure. The message should be unwrapped when it arrives at the destination;
- ContentEnricher—accesses an external data source so as to augment a message with missing information.
3.3. Stereotypes for Structural Components and Messaging Protocols
3.4. Stereotypes for ZeroMQ Framework Patterns
- LazyPirate—polls the socket and receives from it only when it is sure a reply has arrived. If no reply has arrived within a timeout period, the pattern resends a request. The transaction is abandoned if there is no reply after several requests;
- SimplePirate—extends the Lazy Pirate pattern with a queue proxy that allows for transparent communication with multiple servers;
- ParanoidPirate—allows for robust reliable queuing that allows sending and receiving messages at any time but requires its own envelope management;
- Majordomo—adds a service name to requests that the client sends and asks servers to register for specific services. Adding service names turns the Paranoid Pirate pattern from the queue into a service-oriented broker;
- Titanic—stores messages in the message broker to ensure they never get lost;
- BinaryStar—puts two servers in a primary–secondary high-availability pair. At any given time, the active server accepts connections from client applications. The passive server is idle, but the servers monitor each other. If the active server stops working, the passive one takes over as active;
- Freelance—creates a pool of name servers so if one stops working, clients can connect to another. In this architecture, a large set of clients connect to a few servers in a pool directly. The clients connect to the pool, which is the opposite of a broker-based approach such as Majordomo, where clients connect to the broker.
- SuicidalSnail—allows for the detection of slow subscribers. Devoted to subscribers having service-level agreements to guarantee specific maximum latency;
- BlackBox—allows for detection and dealing with high-speed subscribers. The pattern breaks subscriber design into a multithreaded one so that sending and reading messages are in separate sets of threads;
- Espresso—allows for monitoring a publish–subscribe network and works by creating a listener thread that reads a socket and prints anything it gets;
- Clone—builds a shared key-value store. The pattern allows for updating a shared state across a set of clients. To achieve that, the pattern uses key-value pairs, which represent atomic units of change in the shared state.
4. Modeling Method with Examples of Integration Flows
5. Discussion and Limitations
6. Conclusions
Funding
Institutional Review Board Statement
Informed Consent Statement
Data Availability Statement
Conflicts of Interest
References
- Hohpe, G.; Woolf, B. Enterprise Integration Patterns: Designing, Building, and Deploying Messaging Solutions; Addison-Wesley Professional: Boston, MA, USA, 2004. [Google Scholar]
- Apache Camel—An Open-Source Integration Framework. Available online: https://camel.apache.org (accessed on 20 November 2022).
- ZeroMQ—An Open-Source Universal Messaging Library. Available online: https://zeromq.org (accessed on 20 November 2022).
- Daraghmi, E.; Zhang, C.-P.; Yuan, S.-M. Enhancing Saga Pattern for Distributed Transactions within a Microservices Architecture. Appl. Sci. 2022, 12, 6242. [Google Scholar] [CrossRef]
- Martinez, H.F.; Mondragon, O.H.; Rubio, H.A.; Marquez, J. Computational and Communication Infrastructure Challenges for Resilient Cloud Services. Computers 2022, 11, 118. [Google Scholar] [CrossRef]
- Aziz, O.; Farooq, M.S.; Abid, A.; Saher, R.; Aslam, N. Research Trends in Enterprise Service Bus (ESB) Applications: A Systematic Mapping Study. IEEE Access 2020, 8, 31180–31197. [Google Scholar] [CrossRef]
- Ozkaya, M.; Erata, F. A survey on the practical use of UML for different software architecture viewpoints. Inf. Softw. Technol. 2020, 121, 106275. [Google Scholar] [CrossRef]
- Petrasch, R.J.; Petrasch, R.R. Data Integration and Interoperability: Towards a Model-Driven and Pattern-Oriented Approach. Modelling 2022, 3, 105–126. [Google Scholar] [CrossRef]
- Zhong, Y.; Zhu, S.; Wang, Y.; Li, J.; Zhang, X.; Shang, J.S. Pairwise Location-Aware Publish/Subscribe for Geo-Textual Data Streams. IEEE Access 2020, 8, 211704–211713. [Google Scholar] [CrossRef]
- Livaja, I.; Pripužić, K.; Sovilj, S.; Vuković, M. A distributed geospatial publish/subscribe system on Apache Spark. Future Gener. Comput. Syst. 2022, 132, 282–298. [Google Scholar] [CrossRef]
- UML Profile for Messaging Patterns, GitHub Repository. Available online: https://github.com/drGorski/UMLProfile4MessagingPatterns (accessed on 20 November 2022).
- Górski, T. The 1+5 Architectural Views Model in Designing Blockchain and IT System Integration Solutions. Symmetry 2021, 13, 2000. [Google Scholar] [CrossRef]
- Pender, T. Customizing UML Using Profiles. In UML Bible; Wiley Publishing, Inc.: Indianapolis, IN, USA, 2003; pp. 687–723. [Google Scholar]
- Thramboulidis, K.; Christoulakis, F. UML4IoT—A UML-based approach to exploit IoT in cyber-physical manufacturing systems. Comput. Ind. 2016, 82, 259–272. [Google Scholar] [CrossRef]
- Marouane, H.; Duvallet, C.; Makni, A.; Bouaziz, R.; Sadeg, B. An UML profile for representing real-time design patterns. J. King Saud Univ.—Comput. Inf. Sci. 2018, 30, 478–497. [Google Scholar] [CrossRef]
- Plazas, J.E.; Bimonte, S.; Schneider, M.; de Vaulx, C.; Battistoni, P.; Sebillo, M.; Corrales, J.C. Sense, Transform & Send for the Internet of Things (STS4IoT): UML profile for data-centric IoT applications. Data Knowl. Eng. 2022, 139, 101971. [Google Scholar] [CrossRef]
- Wang, H.; Li, H.; Wen, X.; Luo, G. Unified modeling for digital twin of a knowledge-based system design. Robot.-Comput.-Integr. Manuf. 2021, 68, 102074. [Google Scholar] [CrossRef]
- Lee, B.; Kim, D.-K.; Yang, H.; Oh, S. Model transformation between OPC UA and UML. Comput. Stand. Interfaces 2017, 50, 236–250. [Google Scholar] [CrossRef]
- Pauker, F.; Wolny, S.; Fallah, S.M.; Wimmer, M. UML2OPC-UATransforming UML Class Diagrams to OPC UA Information Models. Procedia CIRP 2018, 67, 128–133. [Google Scholar] [CrossRef]
- Kirpitsas, I.K.; Pachidis, T.P. Evolution towards Hybrid Software Development Methods and Information Systems Audit Challenges. Software 2022, 1, 316–363. [Google Scholar] [CrossRef]
- Han, J.; Zhang, Y.; Liu, J.; Li, Z.; Xian, M.; Wang, H.; Mao, F.; Chen, Y. A Blockchain-Based and SGX-Enabled Access Control Framework for IoT. Electronics 2022, 11, 2710. [Google Scholar] [CrossRef]
- Ahmed, W.; Di, W.; Mukathe, D. A Blockchain-Enabled Incentive Trust Management with Threshold Ring Signature Scheme for Traffic Event Validation in VANETs. Sensors 2022, 22, 6715. [Google Scholar] [CrossRef]
- Akhilesh, R.; Bills, O.; Chilamkurti, N.; Chowdhury, M.J.M. Automated Penetration Testing Framework for Smart-Home-Based IoT Devices. Future Internet 2022, 14, 276. [Google Scholar] [CrossRef]
- Messaging Patterns of EIPs. Available online: https://www.enterpriseintegrationpatterns.com/patterns/messaging/toc.html (accessed on 20 November 2022).
- Al-Masri, E.; Kalyanam, K.R.; Batts, J.; Kim, J.; Singh, S.; Vo, T.; Yan, C. Investigating Messaging Protocols for the Internet of Things (IoT). IEEE Access 2020, 8, 94880–94911. [Google Scholar] [CrossRef]
- Velinov, A.; Mileva, A.; Wendzel, S.; Mazurczyk, W. Covert Channels in the MQTT-Based Internet of Things. IEEE Access 2019, 7, 161899–161915. [Google Scholar] [CrossRef]
- Al-Shaibani, H.; Lasla, N.; Abdallah, M. Consortium Blockchain-Based Decentralized Stock Exchange Platform. IEEE Access 2020, 8, 123711–123725. [Google Scholar] [CrossRef]
- Górski, T. Reconfigurable Smart Contracts for Renewable Energy Exchange with Re-Use of Verification Rules. Appl. Sci. 2022, 12, 5339. [Google Scholar] [CrossRef]
- Górski, T. Towards Continuous Deployment for Blockchain. Appl. Sci. 2021, 11, 11745. [Google Scholar] [CrossRef]
Name | Stereotype | Base Type | Icon |
---|---|---|---|
Saga for Synchronized Commits | SyncSaga | UML Action | |
Resilient Publish–Subscribe | ResilientPS | UML Action | |
Pairwise Publish–Subscribe | PairwisePS | UML Action | |
Separate Publish–Subscribe | SeparatePS | UML Action |
Name | Stereotype | Base Type | Icon |
---|---|---|---|
Message Channel | MessageChannel | UML Action | |
Message | Message | UML Action | |
Pipes and Filters | PipesAndFilters | UML Action | |
Message Router | MessageRouter | UML Action | |
Message Translator | MessageTranslator | UML Action | |
MessageEndpoint | MessageEndpoint | UML Action |
Name | Stereotype | Base Type | Icon |
---|---|---|---|
Publish–Subscribe Channel | PublishSubscribe Channel | UML Action | |
Channel Adapter | ChannelAdapter | UML Action | |
Request–Reply | RequestReply | UML Action | |
Saga | Saga | UML Action | |
Durable Subscriber | DurableSubscriber | UML Action | |
Envelope Wrapper | EnvelopeWrapper | UML Action | |
Content Enricher | ContentEnricher | UML Action |
Name | Stereotype | Base Type |
---|---|---|
Apache Camel ActiveMQ | ActiveMQ | UML Component |
RabbitMQ | RabbitMQ | UML Component |
ZeroMQ | ZeroMQ | UML Component |
Name | Stereotype | Base Type |
---|---|---|
Message Queuing Telemetry Transport | MQTT | UML Control Flow |
Advanced Message Queuing Protocol | AMQP | UML Control Flow |
Constrained Application Protocol | CoAP | UML Control Flow |
HyperText Transfer Protocol | HTTP | UML Control Flow |
Extensible Messaging and Presence Protocol | XMPP | UML Control Flow |
Data Distribution Service | DDS | UML Control Flow |
Name | Stereotype | Base Type | Icon |
---|---|---|---|
Lazy Pirate | LazyPirate | UML Action | |
Simple Pirate | SimplePirate | UML Action | |
Paranoid Pirate | ParanoidPirate | UML Action | |
Majordomo | Majordomo | UML Action | |
Titanic | Titanic | UML Action | |
Binary Star | BinaryStar | UML Action | |
Freelance | Freelance | UML Action |
Name | Stereotype | Base Type | Icon |
---|---|---|---|
Suicidal Snail | SuicidalSnail | UML Action | |
Black Box | BlackBox | UML Action | |
Espresso | Espresso | UML Action | |
Clone | Clone | UML Action |
Publisher’s Note: MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations. |
© 2022 by the author. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (https://creativecommons.org/licenses/by/4.0/).
Share and Cite
Górski, T. UML Profile for Messaging Patterns in Service-Oriented Architecture, Microservices, and Internet of Things. Appl. Sci. 2022, 12, 12790. https://doi.org/10.3390/app122412790
Górski T. UML Profile for Messaging Patterns in Service-Oriented Architecture, Microservices, and Internet of Things. Applied Sciences. 2022; 12(24):12790. https://doi.org/10.3390/app122412790
Chicago/Turabian StyleGórski, Tomasz. 2022. "UML Profile for Messaging Patterns in Service-Oriented Architecture, Microservices, and Internet of Things" Applied Sciences 12, no. 24: 12790. https://doi.org/10.3390/app122412790
APA StyleGórski, T. (2022). UML Profile for Messaging Patterns in Service-Oriented Architecture, Microservices, and Internet of Things. Applied Sciences, 12(24), 12790. https://doi.org/10.3390/app122412790