Heroku - Memory Leak

Ok, finally I managed to override the Upload.js plugin. Here is what I needed to import:

extensions/upload/services/Upload.js
extensions/upload/services/image-manipulation.js
extensions/upload/utils

Now I am trying to follow vinod77’s suggestion but since I have little experience with buffers and streams I can not manage to get it working. Could someone here maybe help me solving this last puzzle?

Here is vinod77’s suggestion:

The default Strapi code uses fs.readFile() which uses Buffer, leads to memory leak… So I wrote my own code, using fs.createReadStream() which reads/streams the file all the way…

:arrow_forward: Link to the Upload.js service
:arrow_forward: Link to the cloudinary upload provider