Skip to content

Commit

Permalink
Ignore JVMJ9VM090I message in java -version output (#113)
Browse files Browse the repository at this point in the history
  • Loading branch information
Mesbah-Alam authored Apr 22, 2021
1 parent c1687ef commit b6833d9
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -83,8 +83,9 @@ private JavaVersion(boolean isPrimaryJvm, String javaHome) throws StfException {
throw new StfException("Failed to read result of command: " + javaCmd);
}

// Eat superfluous first lines (e.g. JIT: env var TR_OPTIONS etc, or JVMJ9VM082E Unable to switch to IFA processor)
while (javaVersionOutput.startsWith("JVMJ9VM082E") || javaVersionOutput.startsWith("JIT:")) {
// Eat superfluous first lines (e.g. JIT: env var TR_OPTIONS, or JVMJ9VM082E Unable to switch to IFA processor,
// or JVMJ9VM090I Slow response to network query, etc )
while (javaVersionOutput.startsWith("JVMJ9VM") || javaVersionOutput.startsWith("JIT:")) {
// Line starts with error message. Remove up to and including the newline.
int endOfFirstLine = javaVersionOutput.indexOf('\n');
javaVersionOutput = javaVersionOutput.substring(endOfFirstLine+1);
Expand Down

0 comments on commit b6833d9

Please sign in to comment.