Hello,
Version is; 11,1 . Asp.net core mvc jquery.
We are using the host layer for our mobile application After a while, we get an error while taking tokens.
Our token taking period starts to increase after a while or we cannot perform any token takes. We are waiting for your help about this error. We have 2 different errors in the application logs related to this. These errors are listed below.
Error 1
System.ArgumentNullException: Value cannot be null. (Parameter 'Timeout expired. The timeout period elapsed prior to obtaining a connection from the pool. This may have occurred because all pooled connections were in use and max pool size was reached.') at Name.Web.Controllers.TokenAuthController.Authenticate(AuthenticateModel model) in C:\Users\A\source\repos\Name.ProjectName\src\ProjectName.Web.Core\Controllers\TokenAuthController.cs:line 239 at lambda_method1534(Closure , Object ) at Microsoft.AspNetCore.Mvc.Infrastructure.ActionMethodExecutor.AwaitableObjectResultExecutor.Execute(IActionResultTypeMapper mapper, ObjectMethodExecutor executor, Object controller, Object[] arguments) at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.<InvokeActionMethodAsync>g__Logged|12_1(ControllerActionInvoker invoker) at Microsoft.AspNetCore.Mvc.Infrastructure.ControllerActionInvoker.<InvokeNextActionFilterAsync>g__Awaited|10_0(ControllerActionInvoker invoker, Task lastTask, State next, Scope scope, Object state, Boolean isCompleted)
Value cannot be null. (Parameter 'Timeout expired. The timeout period elapsed prior to obtaining a connection from the pool. This may have occurred because all pooled connections were in use and max pool size was reached.')
Error 2
System.InvalidOperationException: Timeout expired. The timeout period elapsed prior to obtaining a connection from the pool. This may have occurred because all pooled connections were in use and max pool size was reached.
at Microsoft.Data.ProviderBase.DbConnectionFactory.TryGetConnection(DbConnection owningConnection, TaskCompletionSource1 retry, DbConnectionOptions userOptions, DbConnectionInternal oldConnection, DbConnectionInternal& connection) at Microsoft.Data.ProviderBase.DbConnectionInternal.TryOpenConnectionInternal(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource
1 retry, DbConnectionOptions userOptions)
at Microsoft.Data.ProviderBase.DbConnectionClosed.TryOpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource1 retry, DbConnectionOptions userOptions) at Microsoft.Data.SqlClient.SqlConnection.TryOpen(TaskCompletionSource
1 retry, SqlConnectionOverrides overrides) at Microsoft.Data.SqlClient.SqlConnection.Open(SqlConnectionOverrides overrides)
at Microsoft.Data.SqlClient.SqlConnection.Open() at Microsoft.EntityFrameworkCore.SqlServer.Storage.Internal.SqlServerConnection.OpenDbConnection(Boolean errorsExpected)
at Microsoft.EntityFrameworkCore.Storage.RelationalConnection.OpenInternal(Boolean errorsExpected) at Microsoft.EntityFrameworkCore.Storage.RelationalConnection.Open(Boolean errorsExpected)
at Microsoft.EntityFrameworkCore.Storage.RelationalConnection.BeginTransaction(IsolationLevel isolationLevel) at Microsoft.EntityFrameworkCore.RelationalDatabaseFacadeExtensions.<>c__DisplayClass22_0.<BeginTransaction>b__0(DatabaseFacade database)
at Microsoft.EntityFrameworkCore.ExecutionStrategyExtensions.<>c__DisplayClass12_02.<Execute>b__0(DbContext c, TState s) at Microsoft.EntityFrameworkCore.SqlServer.Storage.Internal.SqlServerExecutionStrategy.Execute[TState,TResult](TState state, Func
3 operation, Func`3 veri...
Timeout expired. The timeout period elapsed prior to obtaining a connection from the pool. This may have occurred because all pooled connections were in use and max pool size was reached.
5 Answer(s)
-
0
Hi @tdv.yazilim
Could you answer the questions below, so we can help you.
- Do you use Redis on your app ?
- Could you check if you have the changes in below PRs on your project ?
-
0
Hi, We do not use Redis in token transactions in our application. We also reviewed the codes on github you mentioned above. We did not detect any changes in our project.
We did our experiments on the new empty Zero project. We faced the same problem in the new project.
We did our tests with jmeter with the settings you specified at https://blog.aspnetzero.com/blogs/asp.net-zero/running-load-test-on-asp.net-zero. We are getting this error even in 50 users in our environments.
-
0
Hi @tdv.yazilim
We tried with unmodified latest version and didn't get the error you are getting. Is it possible to share your JMeter test file and sample excel data file ? If we can't reproduce this error with your sample data, we can arrange a meeting and take a look at your project in an online meeting.
-
0
Hi, We have sent the files you requested to the [email protected] e-mail address. We can also show you the problem we encounter as an online meeting.
-
0
Hi @tdv.yazilim
Thanks, we got the email. We will inform you once we test the files you send and we can arrange a meeting.