[GitHub] [maven-surefire] Tibor17 commented on issue #256: repackaged external artifacts (utilities) with no duplicates and use in extensions-api with Commandline
Tibor17 commented on issue #256: repackaged external artifacts (utilities) with no duplicates and use in extensions-api with Commandline URL: https://github.com/apache/maven-surefire/pull/256#issuecomment-562087769 @jon-bell Essentially what you say is that we should close all the streams ater `BYE`. That makes sense. In opposite to that it means that the `InputStream.close()` should not be called on JVM failure (before receiving `BYE` in `ForkClient`). Would it mean that the T2 should close itself stream after `InputStream.read()` has returned `-1`? This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services
[GitHub] [maven-surefire] Tibor17 commented on issue #256: repackaged external artifacts (utilities) with no duplicates and use in extensions-api with Commandline
Tibor17 commented on issue #256: repackaged external artifacts (utilities) with no duplicates and use in extensions-api with Commandline URL: https://github.com/apache/maven-surefire/pull/256#issuecomment-562083080 @jon-bell The problem is a little different from sending serious data. Our ITs fail because closed stream does not see the errors sent when JVM could not start up. This may include serious issues with JVM (class not found) and in our ITs we expect error message from JVM saying that 70MB Xmx cannot be allocated. It s a kind of race condition on the JVM then `Process.waitFor` has returned with non-zero and the streams are closed in the same thread T1 however the thread T2 did not have a chance to read out all bytes completely. This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services
[GitHub] [maven-surefire] Tibor17 commented on issue #256: repackaged external artifacts (utilities) with no duplicates and use in extensions-api with Commandline
Tibor17 commented on issue #256: repackaged external artifacts (utilities) with no duplicates and use in extensions-api with Commandline URL: https://github.com/apache/maven-surefire/pull/256#issuecomment-561068753 @jon-bell How should be the std-out stream drained with all bytes from the process pipe if the process has finished? After the process was finished we have to close the streams but we also should read all bytes. Is it safe enough to rely on value `-1` returned from `InputStream#read()` of the open stream std-out? Wouldn't the method be still waiting? Pls see my last commit https://github.com/apache/maven-surefire/pull/256/commits/ccb823287d75e786e525cc43ebf06ddc62ec2071 This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services
[GitHub] [maven-surefire] Tibor17 commented on issue #256: repackaged external artifacts (utilities) with no duplicates and use in extensions-api with Commandline
Tibor17 commented on issue #256: repackaged external artifacts (utilities) with no duplicates and use in extensions-api with Commandline URL: https://github.com/apache/maven-surefire/pull/256#issuecomment-560211922 @jon-bell This is a preliminary step to the sockets. We discussed it on Slack. Briefly what this provides. Module `surefire-extensions-api` dependent on `maven-shared-utils` caused that the project could not be compiled (problem with relocated packages). Relocating the packages is important. - Finally the first commit made `surefire-extensions-api` dependent on relocated packages and the project can be compiled. The module `surefire-extensions-api` can use the class `Commandline` in public contructor. - The subtypes of `Channel` are applicable to pipes and sockets Java API too - compatible, see `1ba5e55`. - We got rid of the problems with flushing the streams in higher version of `executeCommandLineAsCallable()` of the artifact `maven-shared-utils`. - The impl of future commits would be just one method call (for the proces call) with everything inside of the extension impl, see `71b8fd3`. This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services