Package org.apache.flink.api.java
Class LocalEnvironment
- java.lang.Object
-
- org.apache.flink.api.java.ExecutionEnvironment
-
- org.apache.flink.api.java.LocalEnvironment
-
@Deprecated @Public public class LocalEnvironment extends ExecutionEnvironment
Deprecated.All Flink DataSet APIs are deprecated since Flink 1.18 and will be removed in a future Flink major version. You can still build your application in DataSet, but you should move to either the DataStream and/or Table API.AnExecutionEnvironmentthat runs the program locally, multi-threaded, in the JVM where the environment is instantiated.When this environment is instantiated, it uses a default parallelism of
1. The default parallelism can be set viaExecutionEnvironment.setParallelism(int).Local environments can also be instantiated through
ExecutionEnvironment.createLocalEnvironment()andExecutionEnvironment.createLocalEnvironment(int). The former version will pick a default parallelism equal to the number of hardware contexts in the local machine.
-
-
Field Summary
-
Fields inherited from class org.apache.flink.api.java.ExecutionEnvironment
lastJobExecutionResult, LOG
-
-
Constructor Summary
Constructors Constructor Description LocalEnvironment()Deprecated.Creates a new local environment.LocalEnvironment(org.apache.flink.configuration.Configuration config)Deprecated.Creates a new local environment that configures its local executor with the given configuration.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description StringtoString()Deprecated.-
Methods inherited from class org.apache.flink.api.java.ExecutionEnvironment
addDefaultKryoSerializer, addDefaultKryoSerializer, areExplicitEnvironmentsAllowed, clearJobListeners, configure, createCollectionsEnvironment, createInput, createInput, createLocalEnvironment, createLocalEnvironment, createLocalEnvironment, createLocalEnvironmentWithWebUI, createProgramPlan, createProgramPlan, createProgramPlan, createRemoteEnvironment, createRemoteEnvironment, createRemoteEnvironment, execute, execute, executeAsync, executeAsync, fromCollection, fromCollection, fromCollection, fromCollection, fromElements, fromElements, fromParallelCollection, fromParallelCollection, generateSequence, getConfig, getConfiguration, getDefaultLocalParallelism, getExecutionEnvironment, getExecutionPlan, getExecutorServiceLoader, getJobListeners, getLastJobExecutionResult, getNumberOfExecutionRetries, getParallelism, getRestartStrategy, getUserCodeClassLoader, initializeContextEnvironment, readCsvFile, readFile, readFileOfPrimitives, readFileOfPrimitives, readTextFile, readTextFile, readTextFileWithValue, readTextFileWithValue, registerCachedFile, registerCachedFile, registerJobListener, registerType, registerTypeWithKryoSerializer, registerTypeWithKryoSerializer, resetContextEnvironment, setDefaultLocalParallelism, setNumberOfExecutionRetries, setParallelism, setRestartStrategy
-
-
-
-
Constructor Detail
-
LocalEnvironment
public LocalEnvironment()
Deprecated.Creates a new local environment.
-
LocalEnvironment
public LocalEnvironment(org.apache.flink.configuration.Configuration config)
Deprecated.Creates a new local environment that configures its local executor with the given configuration.- Parameters:
config- The configuration used to configure the local executor.
-
-