OpenLiberty / open-liberty

Open Liberty is a highly composable, fast to start, dynamic application server runtime environment
https://openliberty.io
Eclipse Public License 2.0
1.15k stars 591 forks source link

MVT Server start process management problem #20249

Open tbitonti opened 2 years ago

tbitonti commented 2 years ago

Test debt of #20215

The server start process may need to be terminated. This changes the process result code from 0 to 1.

A temporary code change was made to ignore the return code when the process was terminated.

open-liberty/dev/openliberty.build.image_fat/fat/src/com/ibm/ws/test/image/util/ProcessRunner.java See com.ibm.ws.test.image.util.ProcessRunner.Result.validate com.ibm.ws.test.image.util.ProcessRunner.run

tbitonti commented 2 years ago

For example:

ProcessRunner: Command:
ProcessRunner: [ C:/dev/repos-pub/o-l/dev/openliberty.build.image_fat/build/libs/autoFVT/build/test/iServer/OPEN_LIBERTY_WEB8/wlp/bin/server.bat ]
ProcessRunner: [ start ]
ProcessRunner: Timeout: [ 30000000000 (ns) ]
Captured [ Starting server defaultServer. ]
Captured [ Server defaultServer started. ]
Recording termination [ SUCCEEDED ]
ProcessRunner: Forcibly destroying process
ProcessRunner: Interrupting capture of stderr
Recording termination [ HALTED ]
ProcessRunner: Destroyed [ true ]
ProcessRunner: Return code [ 1 ]
ProcessRunner: Stdout condition [ SUCCEEDED ]
ProcessRunner: Stderr condition [ HALTED ]
ProcessRunner: StdOut [ Starting server defaultServer. ]
ProcessRunner: StdOut [ Server defaultServer started. ]
ProcessRunner: Ignoring return code [ 1 ] expecting [ 0 ]
tbitonti commented 2 years ago

Possibly, the process runner should wait for a second before testing if the process is still alive.