Ensure that the `javaOptions` are set correctly, as `exec` is synchronous.