Hi all, so I recently tried the
psrecord step on Streamlit’s blog and found out that for a single user my app uses a maximum of 150-200Mb which is reasonable (correct me if I’m wrong and you think it’s unreasonable).
HOWEVER, I’m curious to know how memory scales. Does that mean that only 5 users can use the app at one given moment (does it scale linearly; 200x5 = 1GB), or does it not scale at all and all the users’s processes are independent of each other?
Would appreciate some info
It will entirely depend on your app. While there is some universal overhead, how your specific app scales will depend. How much you import from GitHub and how much caching you have will consume resources regardless of concurrent users. The more you load into session state, hold in variables, or perform computations will create an increase in consumption highly dependant on concurrent users.
@mathcatsand Interesting. So just as a general figure, if the app is using 200MB per session (as shown in the plot), does the mean it can only be used by ~ 5 users simultaneously before it peaks the resource limit?
I am unclear exactly how the 1GB “resource limit” combines hard disk vs compute vs RAM in the determination. So glossing over that detail, if your app consumes 200MB when a single user is active, then 5 would be a lower bound of concurrent users. The more of that 200MB goes into general overhead (constant files on disk; stuff stored in cache), then the less the incremental cost I would expect per user.
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.