Skip to content

Commit f762451

Browse files
yanghuazentol
authored andcommitted
[FLINK-13186][clients] Remove unused fields
1 parent 706f610 commit f762451

File tree

1 file changed

+0
-12
lines changed

1 file changed

+0
-12
lines changed

flink-clients/src/main/java/org/apache/flink/client/program/rest/RestClusterClient.java

-12
Original file line numberDiff line numberDiff line change
@@ -139,12 +139,8 @@ public class RestClusterClient<T> extends ClusterClient<T> implements NewCluster
139139

140140
private final LeaderRetrievalService webMonitorRetrievalService;
141141

142-
private final LeaderRetrievalService dispatcherRetrievalService;
143-
144142
private final LeaderRetriever webMonitorLeaderRetriever = new LeaderRetriever();
145143

146-
private final LeaderRetriever dispatcherLeaderRetriever = new LeaderRetriever();
147-
148144
/** ExecutorService to run operations that can be retried on exceptions. */
149145
private ScheduledExecutorService retryExecutorService;
150146

@@ -193,14 +189,12 @@ public RestClusterClient(
193189
} else {
194190
this.webMonitorRetrievalService = webMonitorRetrievalService;
195191
}
196-
this.dispatcherRetrievalService = highAvailabilityServices.getDispatcherLeaderRetriever();
197192
this.retryExecutorService = Executors.newSingleThreadScheduledExecutor(new ExecutorThreadFactory("Flink-RestClusterClient-Retry"));
198193
startLeaderRetrievers();
199194
}
200195

201196
private void startLeaderRetrievers() throws Exception {
202197
this.webMonitorRetrievalService.start(webMonitorLeaderRetriever);
203-
this.dispatcherRetrievalService.start(dispatcherLeaderRetriever);
204198
}
205199

206200
@Override
@@ -216,12 +210,6 @@ public void shutdown() {
216210
log.error("An error occurred during stopping the webMonitorRetrievalService", e);
217211
}
218212

219-
try {
220-
dispatcherRetrievalService.stop();
221-
} catch (Exception e) {
222-
log.error("An error occurred during stopping the dispatcherLeaderRetriever", e);
223-
}
224-
225213
try {
226214
// we only call this for legacy reasons to shutdown components that are started in the ClusterClient constructor
227215
super.shutdown();

0 commit comments

Comments
 (0)