When under heavy load, there are multiple places which result in high memory usage. This ticket is about researching exact locations using pprof for example and implementing fixes to ensure minimal memory consumption:
- JSON decoder/encoder results in high memory usage.
- Exported symbols (imports.go) infinite loop after some time, resulting in just shitload of GBs being used... It's memory leak.