Uploaded image for project: 'JBoss Enterprise Application Platform'
  1. JBoss Enterprise Application Platform
  2. JBEAP-11754

ProcessWrapper.waitForClose shouldn't close the output stream

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Major
    • 7.2.0.CD12
    • 7.1.0.ER1
    • CLI, Test Suite
    • None
    • Not Required

    Description

      This jira is cloned from WFCORE-2985:


      When the output stream is closed, if aesh is reading on the other side of the stream inside the CLI process, this could make the CLI process to exit. That is occurring systematically with aesh-readline.
      ProcessWrapper.waitForClose is called in the following cases:

      • ctrlCAndWaitForClose: The test expects that Ctrl-C will make the process to exit.
      • pushLineAndWaitForClose: The test expects that the passed command will make the process to exit (e.g.: quit)
      • executeNonInteractive: The test expects that the CLI process will exit by itself, no aesh console started (file or command options). In this case, closing the output stream shouldn't hide any issue. But it shouldn't be required either.

      If closing the output stream makes the CLI process to exit it could hide potential CLI issues.

      I suggest that we remove the output stream.close once we have switched to use aesh-readline and see on all platforms how tests are going to behave. We could have exotic platforms that don't make the process to exit properly if output is not closed. We will have to handle them specificaly.

      Attachments

        Issue Links

          Activity

            People

              jdenise@redhat.com Jean Francois Denise
              mkopecky@redhat.com Marek Kopecky
              Erich Duda Erich Duda (Inactive)
              Erich Duda Erich Duda (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: