Possible memory leak in reports


we have a ticket on a bad memory leak: Bug #31200: Puma memory leak - Foreman

The instance seems to be a fact-heavy deployment but I noticed 4 requests on template report generator. This is relatively new feature, are we aware of some memory optimalizations or problems in that code? @mhulan @ezr-ondrej

No matter what we find for that memory leak, I have realized that our batch report generation can be optimized by not storing data in an intermediate array/hash and string, but it can be directly streamed to client or into postgres via SQL COPY statement. I filed a refactor ticket for this: Feature #31274: Reports generation is memory heavy - Foreman

I looked into this but I need to prepare for next week demo, maybe later.