I have issues executing a vbscript by using cscript.exe in non-blocking mode.
Regarding Lucee Docs here i can read this:
A timeout of 0 is equivalent to the non-blocking mode of executing. A very high timeout value is equivalent to a blocking mode of execution. The default is 0; therefore, the thread spawns a process and returns without waiting for the process to terminate.If no output file is specified, and the timeout value is 0, the program output is discarded.
However; let's say the vbscript takes 15 seconds to run, my page stucks for 15 seconds. If i add WScript.Sleep 20000 at the end of the script, then the page stucks for 35 seconds until it returns.
I'm able to reproduce that cfexecute is running in 'blocking' mode regardless if the timeout is set to zero and/or if the timeout parameter is completely removed.
I'm converting an application from CF9 to Lucee. The command from above was executed in non-blocking mode on CF9: The page returned immediately as expected.
Btw: The second statement of the docs is not true as well:
If no output file is specified, and the timeout value is 0, the program output is discarded.
If i execute cfexecute as desribed above, then i do get the output of the script returned to the webpage. Another evidence that the script is executed in blocking mode even it should not; because in non-blocking mode there should be no output returned.
I'm running: *184.108.40.206*
Did someone of you already experienced similar problems?
Windows Server 2016 x64 english, Microsoft IIS
Thanks , Sorry I've confused a little bit. I made a test both ACF 18 and lucee latest version also. Lucee took some more time to execute. But, ACF didn't do the same.
Thanks for the update.
I do not understand what you mean by ‘do the same’.
Do you mean lucee latest version is using blocked-mode even if the timeout is set to '0’ while ACF 2018 executes in non-blocking mode if the timeout is set to '0’?
Did you confirm the different behaviour by this statement and you where able to reproduce it?
Yes, I've confirmed the issue happened on lucee, this issue doesn't happen with the ACF.
If we set timeout = 0 means, lucee running with the blocking mode.
But, ACF didn't work with as same as lucee. It running with the non-blocking mode.
Do you understand?
yes, thanks for the update.