public class LegacyStandaloneClusterDescriptor extends Object implements ClusterDescriptor<StandaloneClusterId>
Constructor and Description |
---|
LegacyStandaloneClusterDescriptor(Configuration config) |
Modifier and Type | Method and Description |
---|---|
void |
close() |
StandaloneClusterClient |
deployJobCluster(ClusterSpecification clusterSpecification,
JobGraph jobGraph,
boolean detached)
Deploys a per-job cluster with the given job on the cluster.
|
StandaloneClusterClient |
deploySessionCluster(ClusterSpecification clusterSpecification)
Triggers deployment of a cluster.
|
String |
getClusterDescription()
Returns a String containing details about the cluster (NodeManagers, available memory, ...).
|
void |
killCluster(StandaloneClusterId clusterId)
Terminates the cluster with the given cluster id.
|
StandaloneClusterClient |
retrieve(StandaloneClusterId standaloneClusterId)
Retrieves an existing Flink Cluster.
|
public LegacyStandaloneClusterDescriptor(Configuration config)
public String getClusterDescription()
ClusterDescriptor
getClusterDescription
in interface ClusterDescriptor<StandaloneClusterId>
public StandaloneClusterClient retrieve(StandaloneClusterId standaloneClusterId) throws ClusterRetrieveException
ClusterDescriptor
retrieve
in interface ClusterDescriptor<StandaloneClusterId>
standaloneClusterId
- The unique identifier of the running clusterClusterRetrieveException
- if the cluster client could not be retrievedpublic StandaloneClusterClient deploySessionCluster(ClusterSpecification clusterSpecification)
ClusterDescriptor
deploySessionCluster
in interface ClusterDescriptor<StandaloneClusterId>
clusterSpecification
- Cluster specification defining the cluster to deploypublic StandaloneClusterClient deployJobCluster(ClusterSpecification clusterSpecification, JobGraph jobGraph, boolean detached)
ClusterDescriptor
deployJobCluster
in interface ClusterDescriptor<StandaloneClusterId>
clusterSpecification
- Initial cluster specification with which the Flink cluster is launchedjobGraph
- JobGraph with which the job cluster is starteddetached
- true if the cluster should be stopped after the job completion without serving the result,
otherwise falsepublic void killCluster(StandaloneClusterId clusterId) throws FlinkException
ClusterDescriptor
killCluster
in interface ClusterDescriptor<StandaloneClusterId>
clusterId
- identifying the cluster to shut downFlinkException
- if the cluster could not be terminatedpublic void close() throws Exception
close
in interface AutoCloseable
Exception
Copyright © 2014–2020 The Apache Software Foundation. All rights reserved.