emoncms / postprocess

Post Processing module for emoncms
GNU Affero General Public License v3.0
3 stars 12 forks source link

Battery simulator process eats all the memory and causes the machine to crash. #22

Open cassman42 opened 3 years ago

cassman42 commented 3 years ago

When running the battery simulator it caused the Pi to crash. Having eaten all of the memory and caused various things to die!

My data goes from May 2016 - hence the process starts 31,449,986 data points behind!

I've looked at the code and added a new method in common.php, this will cause the existing buffered data to be written out and the buffer cleared - so that it doesn't consume all the memory - it also makes the process significantly faster.

cassman42 commented 3 years ago

I've raised a PR

https://github.com/emoncms/postprocess/pull/23