Database Connection Pool in Microservice Architecture

Nur Ayuni Nor Sobri, Mohamad Aqib Haqmi Abas, A. I. Mohd Yassin, M. S. A. Megat Ali, N. Md. Tahir, A. Zabidi
{"title":"Database Connection Pool in Microservice Architecture","authors":"Nur Ayuni Nor Sobri, Mohamad Aqib Haqmi Abas, A. I. Mohd Yassin, M. S. A. Megat Ali, N. Md. Tahir, A. Zabidi","doi":"10.24191/jeesr.v20i1.004","DOIUrl":null,"url":null,"abstract":"29 Abstract—The increase and growing number of users in the internet gives a higher requirement to backend application systems nowadays to be designed to handle thousands of users traffic concurrently. Microservice architecture is also in a rising trend which they allow for each service to scale horizontally by their throughput and load helps to scale the system efficiently without waste of resources like in the traditional monolithic application system. Database connection pool helps for backend systems to access databases efficiently. The present issue is determining the optimal number of database connections to use in a microservice based backend system. This paper aims to find the most suitable amount of database connections in a microservice setting, where multiple instances of the service are used for scalability and high availability purposes of the system. The experiment was conducted by varying the number of database connections from one to five to ten in both single instance and three instance services, where the service being examined is the backend system's roles and permissions service. The results of this experiment indicate that five database connections provide the best performance latency result in a microservice architecture with three service instances. With 2000 requests per second, the maximum latency was 53ms, while the 99th percentile latency was 19ms. The study contributes by determining the optimal size of a database connection pool for use in a microservice architecture with several instances of the service are operating concurrently.","PeriodicalId":313365,"journal":{"name":"Journal of Electrical & Electronic Systems Research","volume":null,"pages":null},"PeriodicalIF":0.0000,"publicationDate":"2022-04-01","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"0","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"Journal of Electrical & Electronic Systems Research","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.24191/jeesr.v20i1.004","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 0

Abstract

29 Abstract—The increase and growing number of users in the internet gives a higher requirement to backend application systems nowadays to be designed to handle thousands of users traffic concurrently. Microservice architecture is also in a rising trend which they allow for each service to scale horizontally by their throughput and load helps to scale the system efficiently without waste of resources like in the traditional monolithic application system. Database connection pool helps for backend systems to access databases efficiently. The present issue is determining the optimal number of database connections to use in a microservice based backend system. This paper aims to find the most suitable amount of database connections in a microservice setting, where multiple instances of the service are used for scalability and high availability purposes of the system. The experiment was conducted by varying the number of database connections from one to five to ten in both single instance and three instance services, where the service being examined is the backend system's roles and permissions service. The results of this experiment indicate that five database connections provide the best performance latency result in a microservice architecture with three service instances. With 2000 requests per second, the maximum latency was 53ms, while the 99th percentile latency was 19ms. The study contributes by determining the optimal size of a database connection pool for use in a microservice architecture with several instances of the service are operating concurrently.
微服务架构中的数据库连接池
摘要:随着互联网用户数量的不断增加和增长,对后端应用系统提出了更高的要求,需要设计成能够同时处理数千个用户的流量。微服务架构也处于上升趋势,它们允许每个服务根据其吞吐量和负载进行水平扩展,这有助于有效地扩展系统,而不会像传统的单片应用系统那样浪费资源。数据库连接池有助于后端系统高效地访问数据库。当前的问题是确定在基于微服务的后端系统中使用的数据库连接的最佳数量。本文旨在找到微服务设置中最合适的数据库连接数量,在微服务设置中,服务的多个实例用于系统的可伸缩性和高可用性目的。在单实例和三实例服务中,通过改变数据库连接的数量从1到5到10来进行实验,其中检查的服务是后端系统的角色和权限服务。实验结果表明,在具有三个服务实例的微服务架构中,五个数据库连接提供了最佳的性能延迟结果。对于每秒2000个请求,最大延迟为53ms,而第99百分位延迟为19ms。该研究通过确定在多个服务实例并发操作的微服务架构中使用的数据库连接池的最佳大小来做出贡献。
本文章由计算机程序翻译,如有差异,请以英文原文为准。
求助全文
约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学术文献互助群
群 号:481959085
Book学术官方微信