I’m getting increasing memory usage when converting a batch of pdf documents to image formats using similar code to this:
public void Function(stream)
{
Aspose.Pdf.Document document = new Aspose.Pdf.Document(stream);
for (int i = 1; i <= document.Pages.Count; i++)
{
ImageDevice device;
device.Process(document.Pages[i], streamOut);
…
}
document.Dispose();
}
I close and dispose all streams after use. Memory goes up to 2GB for 100 files. Preliminary analysis leads to the culprit being ImageDevice (which is not disposable).
Aspose.PDF .Net v19.1.0.0/Win 10 64