This is a migrated thread and some comments may be shown as answers.

Database Connection Pooling Error

4 Answers 68 Views
Databases and Data Types
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Shurland
Top achievements
Rank 1
Shurland asked on 09 Aug 2012, 05:03 PM
I get the following error when browsing the application:

The connection pool has reached it's maxActive setting and a new database connection could not be opened...

Here's how my configuration is set:

    backend.Backend = "mssql"
            backend.ProviderName = "System.Data.SqlClient"
            backend.Logging.MetricStoreSnapshotInterval = 0
            backend.ConnectionPool.BlockWhenFull = False
            backend.Runtime.MediumTrust = True
            backend.Runtime.SupportConcurrentThreadsInScope = True
            backend.Runtime.UseUTCForAutoSetValues = True

Am i doing this correctly, and how can I resolve this issue? The application in question is live as we speak and the client is a very high valued client (T-mobile). I don't think they pick up on this issue yet but I don't want this issue to get me in a big mess. Can someone please help me figure this out? 

Thanks in advanced

4 Answers, 1 is accepted

Sort by
0
Ady
Telerik team
answered on 10 Aug 2012, 11:58 AM
Hello Shurland,

 I noticed that you have set the 'BackendConfiguration.ConnectionPool.BlockWhenFull' property to 'false'. This setting controls the behavior of the connection pool when threads attempt to obtain a connection and there is none available. If set to 'true' (default value) the thread will wait, until one is available. If it is set to False, an exception will be thrown. Do you really want this behavior?
In yes, you should consider increasing the 'ConnectionPool.MaxAxtive' value to an appropriate value but keep in mind that if this new max limit is reached then an exception will be thrown again.

Regards,
Ady
the Telerik team
OpenAccess ORM Q2'12 Now Available! Get your hands on all the new stuff.
0
Shurland
Top achievements
Rank 1
answered on 11 Aug 2012, 07:07 PM
Thanks. I'll try doing that. I have another issue that keeps coming up in my application log, if you can shed some light on this, i'll greatly appreciate it. I don't know how critical it is, but here it goes...

System.Exception: Telerik.OpenAccess.OpenAccessException: This InitState method should not be called. at OpenAccessRuntime.ExceptionWrapper.Throw() at OpenAccessRuntime.DataObjects.PCStateMan.handleException(Exception x) at OpenAccessRuntime.DataObjects.PCStateMan.GetField[T](PersistenceCapable pc, Int32 field, T currentValue) at OpenAccessRuntime.DataObjects.SynchronizedStateManagerProxy.GetField[T](PersistenceCapable pc, Int32 field, T currentValue) at Tmobile.DAL.Core.Invitee.OpenAccessEnhancedGet_UserId(Invitee ) at Tmobile.DAL.Core.Invitee.get_UserId() at Tmobile.BLL.Core.Services.InviteeContext.GetInvitee(String userId) at Tmobile.BLL.Core.Extensions.UserExtensions.Invitee(User entity) at Tmobile.Web.Page.RegistrationPage.get_InviteeId() in E:\HostingSpaces\didwebs\challenger2012.com\wwwroot\challenger\register.aspx.vb:line 203 at Tmobile.Web.Page.RegistrationPage.get_ThisInvitee() in E:\HostingSpaces\didwebs\challenger2012.com\wwwroot\challenger\register.aspx.vb:line 52 at Tmobile.Web.Page.RegistrationPage.SaveInviteeDetails() in E:\HostingSpaces\didwebs\challenger2012.com\wwwroot\challenger\register.aspx.vb:line 214

What is causing this exception, and is it related to the other issue? Please do share.

Thanks,
0
Ady
Telerik team
answered on 16 Aug 2012, 09:57 AM
Hello Shurland,

 This seems to be a completely unrelated problem. Can you open another ticket for this issue and provide some more details as to when you get this exception, the calling code, the persistent model etc.?
A sample project that can reproduce this exception would help in resolving the problem sooner.

All the best,
Ady
the Telerik team
Follow @OpenAccessORM Twitter channel to be the first one to get the latest updates on new releases, tips and tricks and sneak peeks at our product labs!
0
Shurland
Top achievements
Rank 1
answered on 19 Aug 2012, 08:45 PM
Thanks!
Tags
Databases and Data Types
Asked by
Shurland
Top achievements
Rank 1
Answers by
Ady
Telerik team
Shurland
Top achievements
Rank 1
Share this question
or