tillrohrmann closed pull request #6816: [FLINK-10527] Cleanup constant
isNewMode in YarnTestBase
URL: https://github.com/apache/flink/pull/6816
This is a PR merged from a forked repository.
As GitHub hides the original diff on merge, it is displayed below for
the sake of provenance:
As this is a foreign pull request (from a fork), the diff is supplied
below (as it won't show otherwise due to GitHub magic):
diff --git
a/flink-yarn-tests/src/test/java/org/apache/flink/yarn/YARNSessionFIFOITCase.java
b/flink-yarn-tests/src/test/java/org/apache/flink/yarn/YARNSessionFIFOITCase.java
index f027399be7f..fb2c6ccf2b0 100644
---
a/flink-yarn-tests/src/test/java/org/apache/flink/yarn/YARNSessionFIFOITCase.java
+++
b/flink-yarn-tests/src/test/java/org/apache/flink/yarn/YARNSessionFIFOITCase.java
@@ -132,28 +132,6 @@ public void testDetachedMode() throws
InterruptedException, IOException {
// before checking any strings outputted by the CLI, first give
it time to return
clusterRunner.join();
- if (!isNewMode) {
- checkForLogString("The Flink YARN client has been
started in detached mode");
-
- // in legacy mode we have to wait until the TMs are up
until we can submit the job
- LOG.info("Waiting until two containers are running");
- // wait until two containers are running
- while (getRunningContainers() < 2) {
- sleep(500);
- }
-
- // additional sleep for the JM/TM to start and
establish connection
- long startTime = System.nanoTime();
- while (System.nanoTime() - startTime <
TimeUnit.NANOSECONDS.convert(10, TimeUnit.SECONDS) &&
- !(verifyStringsInNamedLogFiles(
- new String[]{"YARN Application Master
started"}, "jobmanager.log") &&
- verifyStringsInNamedLogFiles(
- new String[]{"Starting
TaskManager actor"}, "taskmanager.log"))) {
- LOG.info("Still waiting for JM/TM to
initialize...");
- sleep(500);
- }
- }
-
// actually run a program, otherwise we wouldn't necessarily
see any TaskManagers
// be brought up
Runner jobRunner = startWithArgs(new String[]{"run",
@@ -163,14 +141,12 @@ public void testDetachedMode() throws
InterruptedException, IOException {
jobRunner.join();
- if (isNewMode) {
- // in "new" mode we can only wait after the job is
submitted, because TMs
- // are spun up lazily
- LOG.info("Waiting until two containers are running");
- // wait until two containers are running
- while (getRunningContainers() < 2) {
- sleep(500);
- }
+ // in "new" mode we can only wait after the job is submitted,
because TMs
+ // are spun up lazily
+ LOG.info("Waiting until two containers are running");
+ // wait until two containers are running
+ while (getRunningContainers() < 2) {
+ sleep(500);
}
// make sure we have two TMs running in either mode
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services