Multiple Users Choking App


I have an app using significant data extracted from a postgres database, which I am manipulating and caching. I experience excellent performance with a single user, but as soon as 3 or 4 users connect to my server my app becomes unusable. I believe a new thread is created to rerun the script from top to bottom each time a user interacts with the app, but the time for this to run on a given thread with one user connected is fractions of a second. I wonder precisely how the cache_data functionality is implemented and how it scales with multiple users? Is there some duplicated overhead here? I have read related posts on multi user performance and don’t see any answers that seem to pertain to my issue. Thanks.

1 Like

I ran a memory profiler and this doesn’t seem to be the problem. Also from a CPU resource standpoint, each refresh takes a maximum of about 20% of the resource of a single core, on a 32 core machine. I’m pretty baffled. I wonder if it must be a networking problem? I can’t seem to replicate slow performance by connecting many sessions from my machine locally.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.