Performance comparison of microservices written using reactive and imperative approaches

Kacper Mochniej, Marcin Badurowicz
{"title":"Performance comparison of microservices written using reactive and imperative approaches","authors":"Kacper Mochniej, Marcin Badurowicz","doi":"10.35784/jcsi.3698","DOIUrl":null,"url":null,"abstract":"The purpose of this paper is to compare the performance of microservices based on reactive and imperative approaches. For this purpose, two microservice applications written in Java using the Spring programming framework were developed. The Spring Web and Spring Webflux modules were used for the conventional and reactive versions, respectively. During the tests, functionalities related to operations of retrieving and inserting records into the database, data processing, and file transfer were invoked. The Gatling tool was used to conduct the tests. The tests showed that reactive microservices can be more efficient in particular when there are delays in communication with services or the database. Otherwise, it depends on the complexity of the operations being performed. Microservices based on the reactive paradigm also use less RAM compared to conventional counterparts.","PeriodicalId":480604,"journal":{"name":"Journal of Computer Sciences Institute","volume":"24 1","pages":"0"},"PeriodicalIF":0.0000,"publicationDate":"2023-09-30","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"0","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"Journal of Computer Sciences Institute","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.35784/jcsi.3698","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 0

Abstract

The purpose of this paper is to compare the performance of microservices based on reactive and imperative approaches. For this purpose, two microservice applications written in Java using the Spring programming framework were developed. The Spring Web and Spring Webflux modules were used for the conventional and reactive versions, respectively. During the tests, functionalities related to operations of retrieving and inserting records into the database, data processing, and file transfer were invoked. The Gatling tool was used to conduct the tests. The tests showed that reactive microservices can be more efficient in particular when there are delays in communication with services or the database. Otherwise, it depends on the complexity of the operations being performed. Microservices based on the reactive paradigm also use less RAM compared to conventional counterparts.
使用响应式和命令式方法编写的微服务的性能比较
本文的目的是比较基于响应式和命令式方法的微服务的性能。为此,开发了两个使用Spring编程框架用Java编写的微服务应用程序。Spring Web和Spring Webflux模块分别用于常规版本和响应版本。在测试期间,将调用与检索和将记录插入数据库、数据处理和文件传输等操作相关的功能。使用加特林工具进行测试。测试表明,响应式微服务可以更有效,特别是当与服务或数据库的通信存在延迟时。否则,它取决于所执行操作的复杂性。与传统服务相比,基于响应式范式的微服务也使用更少的RAM。
本文章由计算机程序翻译,如有差异,请以英文原文为准。
求助全文
约1分钟内获得全文 求助全文
来源期刊
自引率
0.00%
发文量
0
×
引用
GB/T 7714-2015
复制
MLA
复制
APA
复制
导出至
BibTeX EndNote RefMan NoteFirst NoteExpress
×
提示
您的信息不完整,为了账户安全,请先补充。
现在去补充
×
提示
您因"违规操作"
具体请查看互助需知
我知道了
×
提示
确定
请完成安全验证×
copy
已复制链接
快去分享给好友吧!
我知道了
右上角分享
点击右上角分享
0
联系我们:info@booksci.cn Book学术提供免费学术资源搜索服务,方便国内外学者检索中英文文献。致力于提供最便捷和优质的服务体验。 Copyright © 2023 布克学术 All rights reserved.
京ICP备2023020795号-1
ghs 京公网安备 11010802042870号
Book学术文献互助
Book学术文献互助群
群 号:604180095
Book学术官方微信
小红书