private int getPort() {
   if (localMode()) {
     return localFlinkCluster.getLeaderRPCPort();
   } else {
     return Integer.parseInt(getProperty("port"));
   }
 }
  private void startFlinkMiniCluster() {
    localFlinkCluster = new LocalFlinkMiniCluster(flinkConf, false);

    try {
      localFlinkCluster.start(true);
    } catch (Exception e) {
      throw new RuntimeException("Could not start Flink mini cluster.", e);
    }
  }
 private void stopFlinkMiniCluster() {
   if (localFlinkCluster != null) {
     localFlinkCluster.stop();
     localFlinkCluster = null;
   }
 }
Esempio n. 4
0
 private void startFlinkMiniCluster() {
   localFlinkCluster = new LocalFlinkMiniCluster(flinkConf, false);
   localFlinkCluster.waitForTaskManagersToBeRegistered();
 }