[
https://issues.apache.org/jira/browse/FLINK-8703?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16417318#comment-16417318
]
ASF GitHub Bot commented on FLINK-8703:
---------------------------------------
Github user pnowojski commented on a diff in the pull request:
https://github.com/apache/flink/pull/5669#discussion_r177743725
--- Diff:
flink-connectors/flink-connector-kafka-base/src/test/java/org/apache/flink/streaming/connectors/kafka/KafkaConsumerTestBase.java
---
@@ -132,8 +140,11 @@
* the same mini cluster. Otherwise, missing slots may happen.
*/
@Before
- public void ensureNoJobIsLingering() throws Exception {
-
JobManagerCommunicationUtils.waitUntilNoJobIsRunning(flink.getLeaderGateway(timeout));
+ public void setClientAndEnsureNoJobIsLingering() throws Exception {
+ client = flink.getClusterClient();
+ while (!getRunningJobs(client).isEmpty()){
--- End diff --
```
while (!getRunningJobs(client).isEmpty()){
Thread.sleep(50);
}
```
This is being copied pasted couple of times. Please extract to common
method. Maybe to an equivalent of `JobManagerCommunicationUtils` or even to
some `TestingClusterClient`?
> Migrate tests from LocalFlinkMiniCluster to MiniClusterResource
> ---------------------------------------------------------------
>
> Key: FLINK-8703
> URL: https://issues.apache.org/jira/browse/FLINK-8703
> Project: Flink
> Issue Type: Sub-task
> Components: Tests
> Reporter: Aljoscha Krettek
> Assignee: Chesnay Schepler
> Priority: Blocker
> Fix For: 1.5.0
>
>
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)