@Public public class RemoteStreamEnvironment extends StreamExecutionEnvironment
DEFAULT_JOB_NAME, isChainingEnabled, transformations
Constructor and Description |
---|
RemoteStreamEnvironment(String host,
int port,
Configuration config,
String... jarFiles)
Creates a new RemoteStreamEnvironment that points to the master
(JobManager) described by the given host name and port.
|
RemoteStreamEnvironment(String host,
int port,
Configuration config,
String[] jarFiles,
URL[] globalClasspaths)
Creates a new RemoteStreamEnvironment that points to the master
(JobManager) described by the given host name and port.
|
RemoteStreamEnvironment(String host,
int port,
String... jarFiles)
Creates a new RemoteStreamEnvironment that points to the master
(JobManager) described by the given host name and port.
|
Modifier and Type | Method and Description |
---|---|
JobExecutionResult |
execute(String jobName)
Triggers the program execution.
|
String |
getHost()
Gets the hostname of the master (JobManager), where the
program will be executed.
|
int |
getPort()
Gets the port of the master (JobManager), where the
program will be executed.
|
String |
toString() |
addDefaultKryoSerializer, addDefaultKryoSerializer, addOperator, addSource, addSource, addSource, addSource, clean, createInput, createInput, createLocalEnvironment, createLocalEnvironment, createLocalEnvironment, createRemoteEnvironment, createRemoteEnvironment, createRemoteEnvironment, disableOperatorChaining, enableCheckpointing, enableCheckpointing, enableCheckpointing, enableCheckpointing, execute, fromCollection, fromCollection, fromCollection, fromCollection, fromElements, fromParallelCollection, fromParallelCollection, generateSequence, getBufferTimeout, getCheckpointConfig, getCheckpointingMode, getCheckpointInterval, getConfig, getExecutionEnvironment, getExecutionPlan, getNumberOfExecutionRetries, getParallelism, getRestartStrategy, getStateBackend, getStreamGraph, getStreamTimeCharacteristic, initializeContextEnvironment, isChainingEnabled, isForceCheckpointing, readFile, readFileStream, readTextFile, readTextFile, registerType, registerTypeWithKryoSerializer, registerTypeWithKryoSerializer, resetContextEnvironment, setBufferTimeout, setDefaultLocalParallelism, setNumberOfExecutionRetries, setParallelism, setRestartStrategy, setStateBackend, setStreamTimeCharacteristic, socketTextStream, socketTextStream, socketTextStream
public RemoteStreamEnvironment(String host, int port, String... jarFiles)
host
- The host name or address of the master (JobManager), where the
program should be executed.port
- The port of the master (JobManager), where the program should
be executed.jarFiles
- The JAR files with code that needs to be shipped to the
cluster. If the program uses user-defined functions,
user-defined input formats, or any libraries, those must be
provided in the JAR files.public RemoteStreamEnvironment(String host, int port, Configuration config, String... jarFiles)
host
- The host name or address of the master (JobManager), where the
program should be executed.port
- The port of the master (JobManager), where the program should
be executed.config
- The configuration used to parametrize the client that connects to the
remote cluster.jarFiles
- The JAR files with code that needs to be shipped to the
cluster. If the program uses user-defined functions,
user-defined input formats, or any libraries, those must be
provided in the JAR files.public RemoteStreamEnvironment(String host, int port, Configuration config, String[] jarFiles, URL[] globalClasspaths)
host
- The host name or address of the master (JobManager), where the
program should be executed.port
- The port of the master (JobManager), where the program should
be executed.config
- The configuration used to parametrize the client that connects to the
remote cluster.jarFiles
- The JAR files with code that needs to be shipped to the
cluster. If the program uses user-defined functions,
user-defined input formats, or any libraries, those must be
provided in the JAR files.globalClasspaths
- The paths of directories and JAR files that are added to each user code
classloader on all nodes in the cluster. Note that the paths must specify a
protocol (e.g. file://) and be accessible on all nodes (e.g. by means of a NFS share).
The protocol must be supported by the URLClassLoader
.public JobExecutionResult execute(String jobName) throws ProgramInvocationException
StreamExecutionEnvironment
The program execution will be logged and displayed with the provided name
execute
in class StreamExecutionEnvironment
jobName
- Desired name of the jobProgramInvocationException
public String getHost()
public int getPort()
Copyright © 2014–2017 The Apache Software Foundation. All rights reserved.