• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How can we deal if Users are exceeded to connection pool size

 
Rama Satti
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Hi to all,

I came across the question in an interview. The scenario like this,

for example our connection pool size is: 200. Currently 200 users (all Active users) are accessing the site.
What is going to happen if a new user(201th user) is going to access the site.
How can we deal the situation?


Discuss all situations we need to take care of, when we came across this situation.

Thanks in advance.

Regards
Krishna
 
Vijitha Kumara
Bartender
Pie
Posts: 3930
21
Chrome Fedora Hibernate
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
One thing I can think of, reduce the scope to minimum in which the connections are used in the application (of course this is in the code level). But as with your statement if all 200 connections are in use at the same time then the next user will simple have to wait.
 
Ulf Dittmer
Rancher
Posts: 42969
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I think it's unlikely that all 200 users will access the web app in a way so that 200 connections will be open at the same time. While it's a possibility (and obviously depends on the application), I'd say that a pool of size 50 should be plenty big enough to serve 200 simultaneous users.

Most likely, I wouldn't make the pool bigger than 50 (rather smaller), because the DB is not going to be particularly responsive it if has to handle 50 queries at the exact same time.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic