React App - Queueing State

JayC

Well-Known Member
Aug 8, 2013
5,509
1,401
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?
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");
});
});
 

Pinkman

Posting Freak
Jul 27, 2016
819
194
I assume this is hosted on a server? Have you checked whether cpu or ram useage spikes up? From reading your thread and saying no git changes has been done it could be related to a latency/server issue perhaps?
 

JayC

Well-Known Member
Aug 8, 2013
5,509
1,401
I assume this is hosted on a server? Have you checked whether cpu or ram useage spikes up? From reading your thread and saying no git changes has been done it could be related to a latency/server issue perhaps?
I thought this was the issue. I upgraded the server from 2 to 4 cores, 4GB to 8GB of ram, 500mb bandwidth to 1GB. It's a very light-weight app that only a couple of users are utilizing at a time.
Post automatically merged:

Are they "queuing" from the client side, or do you mean the server side, and it takes that amount of time for the requests to hit the server?
I think its queueing from the client side. When using the chrome browser tool it shows as "Queueing" for 6 seconds, and the "time for server response" is < 200ms
 

Weasel

👄 I'd intercept me
Nov 25, 2011
4,146
2,469
I thought this was the issue. I upgraded the server from 2 to 4 cores, 4GB to 8GB of ram, 500mb bandwidth to 1GB. It's a very light-weight app that only a couple of users are utilizing at a time.
Post automatically merged:


I think its queueing from the client side. When using the chrome browser tool it shows as "Queueing" for 6 seconds, and the "time for server response" is < 200ms

We actually had this very weird issue back at one of my previous jobs. Actually spent quite some time on this with multiple people. The root cause turned out to be something with Cloudflare. We had to give them A LOT of data to finally fix it.

In our case it was limited to specific geographical areas. Not sure if you have anything of Cloudflare infra in the setup?
 

JayC

Well-Known Member
Aug 8, 2013
5,509
1,401
We actually had this very weird issue back at one of my previous jobs. Actually spent quite some time on this with multiple people. The root cause turned out to be something with Cloudflare. We had to give them A LOT of data to finally fix it.

In our case it was limited to specific geographical areas. Not sure if you have anything of Cloudflare infra in the setup?
I am using cloudflare. I had disabled cloudflare, which supposedly is supposed to bypass their network all together, and it didn't change the results....
 

Weasel

👄 I'd intercept me
Nov 25, 2011
4,146
2,469
I am using cloudflare. I had disabled cloudflare, which supposedly is supposed to bypass their network all together, and it didn't change the results....

IIRC it had something to do with the nameservers, so even disabling Cloudflare didn't fix it. Is it from everywhere, so even when you use a VPN with different locations?
 

Users who are viewing this thread

Top