[IT][Bug]ServerITCaseBase fails when stderr contains "Picked up JAVA_TOOL_OPTIONS"
- Dominant language
- Java
- Stars
- 2.1k
- Forks
- 625
- Avg merge
- 3d 14h
- Merged PRs (30d)
- 97
Description
### Search before asking
- [x] I searched in the [issues](https://github.com/apache/fluss/issues) and found nothing similar.
### Fluss version
0.8.0 (latest release)
### Please describe the bug 🐞
### Summary
https://github.com/apache/fluss/blob/e2d06573a204cb7cb23f9555d1bf5794924f5733/fluss-server/src/test/java/org/apache/fluss/server/ServerITCaseBase.java#L118
`ServerITCaseBase` treats any stderr output from the spawned server process as a startup failure. In Jenkins with `withMaven`, every JVM prints a line like:
Picked up JAVA_TOOL_OPTIONS: -Dmaven.ext.class.path=".../pipeline-maven-spy.jar" -Dorg.jenkinsci.plugins.pipeline.maven.reportsFolder="..."
This line goes to stderr and causes CoordinatorServerITCase / TabletServerITCase to fail even though the server starts.
### Error
CoordinatorServerITCase.testRunServerUsingProcess(Path)
Server process failed to start: Picked up JAVA_TOOL_OPTIONS: ...
### Environment
- CI: Jenkins (withMaven enabled)
- JDK: 17
- Maven: Maven Wrapper (3.8.6) / Maven 3.6.1
### Reproduction
Run integration tests in a Jenkins pipeline with `withMaven` enabled:
```
java.lang.IllegalStateException:
Server process failed to start: Picked up JAVA_TOOL_OPTIONS: -Dfile.encoding=UTF-8 -Dmaven.ext.class.path="/jenkins/workspace/wap-udp-fluss_add-jenkins@tmp/withMavene743bf1a/pipeline-maven-spy.jar" -Dorg.jenkinsci.plugins.pipeline.maven.reportsFolder="/jenkins/workspace/wap-udp-fluss_add-jenkins@tmp/withMavene743bf1a"
at org.apache.fluss.server.ServerITCaseBase.waitUntilServerStartup(ServerITCaseBase.java:123)
at org.apache.fluss.server.ServerITCaseBase.testRunServerUsingProcess(ServerITCaseBase.java:93)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:569)
at org.junit.platform.commons.util.ReflectionUtils.invokeMethod(ReflectionUtils.java:727)
at org.junit.jupiter.engine.execution.MethodInvocation.proceed(MethodInvocation.java:60)
at org.junit.jupiter.engine.execution.InvocationInterceptorChain$ValidatingInvocation.proceed(InvocationInterceptorChain.java:131)
at org.junit.jupiter.engine.extension.TimeoutExtension.intercept(TimeoutExtension.java:156)
at org.junit.jupiter.engine.extension.TimeoutExtension.interceptTestableMethod(TimeoutExtension.java:147)
at org.junit.jupiter.engine.extension.TimeoutExtension.interceptTestMethod(TimeoutExtension.java:86)
at org.junit.jupiter.engine.execution.InterceptingExecutableInvoker$ReflectiveInterceptorCall.lambda$ofVoidMethod$0(Intercept
```
### Solution
### Expected
The test should only fail on real server startup errors, not on the `Picked up JAVA_TOOL_OPTIONS` banner.
### Actual
The test fails immediately because stderr is non-empty.
### Proposed Fix
Filter out lines that start with `Picked up JAVA_TOOL_OPTIONS:` when deciding whether server startup failed, or only fail on stderr lines that indicate real errors.
### Are you willing to submit a PR?
- [x] I'm willing to submit a PR!
Contributor guide
No contributing guide indexed for this repository
Research direction
Start in fluss-server/src/test/java/org/apache/fluss/server/ServerITCaseBase.java around lines 93 and 118, especially waitUntilServerStartup. Reproduce with the CoordinatorServerITCase and TabletServerITCase integration tests under Jenkins withMaven, then verify that the JAVA_TOOL_OPTIONS banner no longer causes startup failure while genuine server errors still do.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- testing-qa
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 58/100