metanorma / mn2pdf-ruby

Ruby gem wrapper for mn2pdf
1 stars 1 forks source link

Allow configuration of mn2pdf stack and heap space #39

Closed ronaldtse closed 2 months ago

ronaldtse commented 6 months ago

From:

The change starts here: https://github.com/metanorma/mn2pdf-ruby/blob/7c981c12fac46b25c62845a965862433fd577391/lib/mn2pdf.rb#L8

We need to be able to change the JVM memory options:

So we need a way to configure these through library method invocation. These parameters are directly used by:

CAMOBAP commented 2 months ago

I think it should read JAVA opts from env (JAVA_OPTS) and ensure that ss and mx are at least 5m and 2048m. this will allow to change it and give final client flexibility also for huge docs

An alternative approach for passing through metanorma-cli looks complex and redundant and make sense only for our code and not external tools

CAMOBAP commented 2 months ago

Implemented via JAVA_OPTS env var