JayC
Well-Known Member
I have an application that I've been running for awhile. I can't find any changes in my git history that would explain this issue. I haven't changed any configuration on the server either.
My react application will get hung up where requests are stuck in a "queueing" state for 2-10 seconds. It doesn't happen every time. It is random requests, not necessarily the same ones.
For example, there is a search box I have that looks up some records in the database. When I press search it only re-renders the page one time to add a spinner. There is only one API request sent, and that's the only thing in the network tab of chrome dev tools. If I search 30 times in a row, 2-3 of those requests may get stuck "queueing" and then 1 may result in a network error due to the response not being returned before the timeout of the browser.
Has anyone experienced an issue with queueing requests like this?
This is my cors configuration
My react application will get hung up where requests are stuck in a "queueing" state for 2-10 seconds. It doesn't happen every time. It is random requests, not necessarily the same ones.
For example, there is a search box I have that looks up some records in the database. When I press search it only re-renders the page one time to add a spinner. There is only one API request sent, and that's the only thing in the network tab of chrome dev tools. If I search 30 times in a row, 2-3 of those requests may get stuck "queueing" and then 1 may result in a network error due to the response not being returned before the timeout of the browser.
Has anyone experienced an issue with queueing requests like this?
Post automatically merged:
This is my cors configuration
services.AddCors(options =>
{
options.AddPolicy("AllowSubdomains",
builder =>
{
builder.SetIsOriginAllowed(origin =>
{
var uri = new Uri(origin);
return uri.Host == "myurl");
})
.AllowAnyMethod()
.AllowAnyHeader()
.AllowCredentials();
builder.WithExposedHeaders("Access-Control-Max-Age");
});
});