Skip to content
⌘ NSIS Forum Archive

ExecDos hanging on Java process

4 posts

kalverson#

ExecDos hanging on Java process

This is just to document that it happened. I resolved my issue by using the older nsExec in place of ExecDos. I lose the output in the log, but it does not hang. Something about the Java output from flyway.cmd version 3.1 is causing ExecDos to hang up. When the same process is run in a command shell it runs fine. JStack on the hanging process just shows Java is outputting; there doesn't seem to be anything suspicious.
kalverson#
The 4k pipe is probably filling up. From a Google link on why Java processes hang:

Java doesn't do anything in this area. It just uses OS services to create the pipes. All Unix like OSs and Windows behave the same in this regard: A pipe with a 4K is created between parent and child. When that pipe is full (because one side isn't reading), the writing process blocks. This is the standard since the inception of pipes. There is not much Java can do.
aerDNA#
I resolved my issue by using the older nsExec in place of ExecDos. I lose the output in the log, but it does not hang.
What about nsExec::ExecToLog ?
kalverson#
I haven't tried the logging part yet. I did run into this same issue again with a different product running a postgresql sql script. Once again the install hangs on ExecDos.