geoip-attack-map
geoip-attack-map copied to clipboard
Memory Use / Variable Size
One of the big issues with DataServer.py is that memory is constantly consumed. Variables are ever growing, and this needs to change, so maybe we should use a database? I'm thinking we incorporate mongodb, and track metrics there. That way variables aren't tracking metrics the entire time, and we save on memory space.
Thoughts/Ideas?
Yes ... the created objects are huge and store numeric data that could be in a database. This will make it easier to generate reports. Good idea. A simple bank I use here is SQLITE. One more option.
I've been learning more about Redis, and would like to withdraw my MongoDB statement. In upcoming days/weeks I will begin working on an implementation that tracks stats using Redis. It will still be in memory, but we can control how large we want data sets to grow, persistence, and speed.
I disabled the console.log of the code and solved the browser memory problem here. It's been working for days without crashing.