The documentation mentions the following:
Local Service Errors
If you encounter the message "Local service exited with error" in your runtime logs, for example:
com.mendix.modules.microflowengine.MicroflowException: com.mendix.systemwideinterfaces.MendixRuntimeException: java.lang.RuntimeException: Local service exited with error at DocumentGenerationTest.ACT_TestDocument_WrongLayout (JavaAction : 'Generate PDF from page')
We recommend that you temporarily set the log level of the DocumentGeneration log node to trace. This should give more insight at what stage the action fails.
Edit: The OP Florian mentioned that reinstalling the module fixed the issue. I'm only copying this so that the question can be marked as "answered", which helps other people in the future find relevant threads that have a known solution.
Thank you.
We reinstalled the module and now it is working.