Strong typing for event-driven microservice architecture
Abstract
Microservice architecture is a popular approach for building various systems. It consists of various dedicated small-sized components from a solid application. Components work together and provide the required business-logic but each one can be implemented with the most suitable technique. Moreover, overloaded parts can be scaled easily. However, data transfer layer does not guarantee compatibility of services during their development. After changing input or output data type of any microservice of the system there are too little ways to keep up compatibility of all other services. The problem is especially urgent for asynchronous communication because existing systems and standards work mostly with synchronous RPC or REST interoperation or cover high-level description of business-logic. One approach to guarantee compatibility of all services in the system is a preliminary check of data types before the services start to work. The previous paper considers realization of the mentioned approach with the dedicated service that checks types, connects services using description of the interfaces. The current paper covers further development of the approach: a system built with preliminary check of data types supports only asynchronous communication and all checks are provided by a message broker. We have implemented and compared simplified approach with alternative ways and have come to the conclusion that described way solves the problem of type inconsistency in a microservice event-driven architecture in a more convenient way than alternatives.
References
R. Rodger, The tao of microservices, New York: Manning Publications Company, 2018, pp. 17–19.
N. Kratzke, “A Brief History of Cloud Application Architectures,” Applied Sciences, vol. 8, no. 8, 2018; doi: 10.3390/app8081368
M. Richards, Microservices vs. service-oriented architecture, Sebastopol: O’Reilly Media, 2015.
Q. Z. Sheng, X. Qiao, A. V. Vasilakos, C. Szabo, S. Bourne, and X. Xu, “Web services composition: A decade’s overview,” Information Sciences, vol. 280, pp. 218–238, 2014; doi: 10.1016/j.ins.2014.04.054
F. Casati and M. C. Shan, “Dynamic and adaptive composition of e-services,” Information Systems, no. 26, pp. 143–163, 2001; doi: 10.1016/S0306-4379(01)00014-X
A. Lazcano, G. Alonso, H. Schuldt, and C. Schuler, “The WISE approach to electronic commerce,” International Journal of Computer Systems Science and Engineering, vol. 15, no. 5, pp. 343–355, 2000.
F. Lecue, Y. Gorronogoitia, R. Gonzalez, M. Radzimski, and M. Villa, “SOA4All: an innovative integrated approach to services composition,” in Proc. 8th IEEE Int. Conf. on Web Services (ICWS’10), Miami, FL, USA, 2010, pp. 58—67; doi: 10.1109/ICWS.2010.68
A. L. Lemos, F. Daniel, and B. Benatallah, “Web Service Composition: A Survey of Techniques and Tools,” ACM Computing Surveys (CSUR), vol. 48, no. 3, pp. 1–41, 2015; doi: 10.1145/2831270
K. Verma, K. Sivashanmugam, A. Sheth, A. Patil, S. Oundhakar, and J. Miller, “METEOR-S WSDI: A Scalable P2P Infrastructure of Registries for Semantic Publication and Discovery ofWeb Services,” Information Technology and Management, vol. 6, no. 1, pp. 17–39, 2005; doi: 10.1007/s10799-004-7773-4
B. Orriens and J. Yang, “A Rule Driven Approach for Developing Adaptive Service Oriented Business Collaboration,” IEEE Int. Conf. on Services Computing (SCC’06), Chicago, IL, USA, 2006; doi:10.1109/SCC.2006.14.
M. Colombo, E. Di Nitto, and M. Mauri, “SCENE: A Service Composition Execution Environment Supporting Dynamic Changes Disciplined Through Rules,” in Service-Oriented Computing, A. Dan and W. Lamersdorf eds., 006; doi: 10.1007/11948148_16
S. R. Ponnekanti and A. Fox, “Sword: A developer toolkit for web service composition,” Proc. 11th Int. WWWConf, Honolulu, HI, USA, 2002.
L. Sun, H. Dong, F. Hussain, O. Hussain, E. Chang, “Cloud service selection: State-of-the-art and future research directions,” Journal of Network and Computer Applications, vol. 45, pp. 134–150, 2014; doi: 10.1016/j.jnca.2014.07.019
N. Gerasimov, “Static typing and dependency management for SOA,” Position Papers of the 2018 Federated Conference on Computer Science and Information Systems, vol. 16, pp. 105–107, 2018.
A. Wright, H. Andrews and G. Luff, “JSON Schema Validation: A Vocabulary for Structural Validation of JSON,” [Online]. Available: http://jsonschema.org/latest/json-schema-validation.html
B. Pierce, Types and Programming Languages London: MIT Press, 2002, pp. 251–254.
This work is licensed under a Creative Commons Attribution 4.0 International License.