Class StandaloneClusterDescriptor
java.lang.Object
org.apache.flink.client.deployment.StandaloneClusterDescriptor
- All Implemented Interfaces:
AutoCloseable,ClusterDescriptor<StandaloneClusterId>
public class StandaloneClusterDescriptor
extends Object
implements ClusterDescriptor<StandaloneClusterId>
A deployment descriptor for an existing cluster.
-
Constructor Summary
ConstructorsConstructorDescriptionStandaloneClusterDescriptor(org.apache.flink.configuration.Configuration config) -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()deployApplicationCluster(ClusterSpecification clusterSpecification, ApplicationConfiguration applicationConfiguration) Triggers deployment of an application cluster.deploySessionCluster(ClusterSpecification clusterSpecification) Triggers deployment of a cluster.Returns a String containing details about the cluster (NodeManagers, available memory, ...).voidkillCluster(StandaloneClusterId clusterId) Terminates the cluster with the given cluster id.retrieve(StandaloneClusterId standaloneClusterId) Retrieves an existing Flink Cluster.
-
Constructor Details
-
StandaloneClusterDescriptor
public StandaloneClusterDescriptor(org.apache.flink.configuration.Configuration config)
-
-
Method Details
-
getClusterDescription
Description copied from interface:ClusterDescriptorReturns a String containing details about the cluster (NodeManagers, available memory, ...).- Specified by:
getClusterDescriptionin interfaceClusterDescriptor<StandaloneClusterId>
-
retrieve
public ClusterClientProvider<StandaloneClusterId> retrieve(StandaloneClusterId standaloneClusterId) throws ClusterRetrieveException Description copied from interface:ClusterDescriptorRetrieves an existing Flink Cluster.- Specified by:
retrievein interfaceClusterDescriptor<StandaloneClusterId>- Parameters:
standaloneClusterId- The unique identifier of the running cluster- Returns:
- Client for the cluster
- Throws:
ClusterRetrieveException- if the cluster client could not be retrieved
-
deploySessionCluster
public ClusterClientProvider<StandaloneClusterId> deploySessionCluster(ClusterSpecification clusterSpecification) Description copied from interface:ClusterDescriptorTriggers deployment of a cluster.- Specified by:
deploySessionClusterin interfaceClusterDescriptor<StandaloneClusterId>- Parameters:
clusterSpecification- Cluster specification defining the cluster to deploy- Returns:
- Client for the cluster
-
deployApplicationCluster
public ClusterClientProvider<StandaloneClusterId> deployApplicationCluster(ClusterSpecification clusterSpecification, ApplicationConfiguration applicationConfiguration) Description copied from interface:ClusterDescriptorTriggers deployment of an application cluster. This corresponds to a cluster dedicated to the execution of a predefined application. The cluster will be created on application submission and torn down upon application termination. In addition, themain()of the application's user code will be executed on the cluster, rather than the client.- Specified by:
deployApplicationClusterin interfaceClusterDescriptor<StandaloneClusterId>- Parameters:
clusterSpecification- Cluster specification defining the cluster to deployapplicationConfiguration- Application-specific configuration parameters- Returns:
- Client for the cluster
-
killCluster
Description copied from interface:ClusterDescriptorTerminates the cluster with the given cluster id.- Specified by:
killClusterin interfaceClusterDescriptor<StandaloneClusterId>- Parameters:
clusterId- identifying the cluster to shut down- Throws:
org.apache.flink.util.FlinkException- if the cluster could not be terminated
-
close
public void close()- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceClusterDescriptor<StandaloneClusterId>
-