1

I want to set the max pool size - 1000. I want to know what is the limit of max pool size in.Net application . will it work fine if i make pool size - 1000

<add name="Constr" connectionString="Server=.;database=DBName;Trusted_connection=true;pooling=true;Max Pool Size=1000;MultipleActiveResultSets=True" providerName="System.Data.SqlClient" />
  • this may help : http://www.codeproject.com/Questions/683855/Is-necessary-to-add-max-connection-pool-in-asp-net – Sora Aug 20 '15 at 07:17
  • 1
    Sql server here is the one that may and will likely will restrict the pool size not asp.net. You'r application should not need to have 1000 connections open at the same time, so there shouldn't be a need for so large connection pool. Close your connections as soon as they are not needed. – Esko Aug 20 '15 at 07:17
  • http://stackoverflow.com/questions/8602380/what-is-maximum-allowable-value-of-max-pool-size-in-sql-connection-string – potatopeelings Aug 20 '15 at 07:23
  • You should be more interesting in `disposing/closing connections` properly than increasing `max pool size` limits. – shashwat Aug 20 '15 at 07:25
  • as per my requirement im keeping 1000 connections but ,,i want to know is there any linit of connections?? kindly tell me @shashwat –  Aug 20 '15 at 07:32
  • Is there any disadvantage (performance wise) if one gives a large number for max pool size. lets say 5000 ??? – Tiyyob Aug 19 '20 at 08:10

1 Answers1

2

SQL Server allows a maximum of 32,767 user connections. You can set max pool size up to 32767.

enter image description here

For more detail please check this link.

Jayesh Goyani
  • 11,008
  • 11
  • 30
  • 50
  • 2
    This has literally nothing to do with the original question. The point of .Net connection pooling is to re-use connections so that you don't affect the connection count on the SQL server as much. – Dockstar Feb 16 '18 at 14:59
  • @Dockstar Isn't it to re-use connections so that they don't need to be setup again and again? – Ian Warburton Oct 05 '22 at 16:57
  • @IanWarburton That's the point of the pool. The user's question was about .net and setting its connection pool size. The point of the connection pool is, as you said, to keep from re-creating user connections. The answer here shows nothing more than the maximum number of connections that SQL server allows, which is not related to the ASP.net pool size – Dockstar Oct 06 '22 at 13:46