Quoted By:
Hello all, trial dev here, with a slightly better explained form of my ramblings in GC.
Been digging through things for a while and might have found the root cause of the issue. Browser local storage is a rough limit of 5MB, and getStats is around 7MB. The stats in that file consist of data points for the graphs. We have two contributions recently that looks to have caused this. Males and activity across the board seems to be way up causing the size of the file to grow and thus your browser clears this every so often I guess, meaning we have to call the api again to get the data back.
Basically every coin we add increases the data by a decent-ish portion, every day that passes increases the data slightly.
The too indepth bit on this, basically the graph updates every 15 unique trades or every 15minutes, whichever is first. On good deals this means we are updating that coin nearly every minute as everyone buys it. On bad deals/coins that didn't change much it seems like it averages to maybe once every 5minutes. So worst case scenario in a day there is up to 1440 data points (of unique numbers), best case its 288. Lets just say an average of this is 500, per coin. For some reason we also mimic this exact behaviour for 'shares in circulation', so its about 1k data per coin, each day. For the rest of the graphs we have just daily totals, so lets say this is about 400 days of data? With 8 graph options and 66 coins this is 211k data points.
For daily data points the total is 1k * 66 coins = 66k data points (remember this is rough work).
How to fix this? A few different ways I guess but easy ones is limit the graph updates to 5-15 minutes for price, every 30min-1hr for circulation, 66k -> 288*48*66=22k. If we keep just the past 6 months of daily data totals and then average the rest to weekly this saves about 1/2 of the 211k.
In the meantime i'm going to try look into preventing the whitescreens until its fixed by maybe giving it 0's if it doesn't have the data? Not fully sure on the best approach, but graphs would probably look broken if you reach the limit, but you could still trade which I assume is most peoples priority.
TLDR males+activity broke nasfaq.. I did ask you guys to vote no...
-trial dev