Package org.apache.flink.table.api
Class EnvironmentSettings
- java.lang.Object
-
- org.apache.flink.table.api.EnvironmentSettings
-
@PublicEvolving public class EnvironmentSettings extends Object
Defines all parameters that initialize a table environment. Those parameters are used only during instantiation of aTableEnvironmentand cannot be changed afterwards.Example:
EnvironmentSettings.newInstance() .inStreamingMode() .withBuiltInCatalogName("default_catalog") .withBuiltInDatabaseName("default_database") .build()inStreamingMode()orinBatchMode()might be convenient as shortcuts.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classEnvironmentSettings.BuilderA builder forEnvironmentSettings.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetBuiltInCatalogName()Gets the specified name of the initial catalog to be created when instantiating aTableEnvironment.StringgetBuiltInDatabaseName()Gets the specified name of the default database in the initial catalog to be created when instantiating aTableEnvironment.org.apache.flink.table.catalog.CatalogStoregetCatalogStore()org.apache.flink.configuration.ConfigurationgetConfiguration()Get the underlyingConfiguration.ClassLoadergetUserClassLoader()Returns the userClassLoaderto use for code generation, UDF loading and other operations requiring reflections on user code.static EnvironmentSettingsinBatchMode()Creates a default instance ofEnvironmentSettingsin batch execution mode.static EnvironmentSettingsinStreamingMode()Creates a default instance ofEnvironmentSettingsin streaming execution mode.booleanisStreamingMode()Tells if theTableEnvironmentshould work in a batch or streaming mode.static EnvironmentSettings.BuildernewInstance()Creates a builder for creating an instance ofEnvironmentSettings.
-
-
-
Method Detail
-
inStreamingMode
public static EnvironmentSettings inStreamingMode()
Creates a default instance ofEnvironmentSettingsin streaming execution mode.In this mode, both bounded and unbounded data streams can be processed.
This method is a shortcut for creating a
TableEnvironmentwith little code. Use the builder provided innewInstance()for advanced settings.
-
inBatchMode
public static EnvironmentSettings inBatchMode()
Creates a default instance ofEnvironmentSettingsin batch execution mode.This mode is highly optimized for batch scenarios. Only bounded data streams can be processed in this mode.
This method is a shortcut for creating a
TableEnvironmentwith little code. Use the builder provided innewInstance()for advanced settings.
-
newInstance
public static EnvironmentSettings.Builder newInstance()
Creates a builder for creating an instance ofEnvironmentSettings.
-
getConfiguration
public org.apache.flink.configuration.Configuration getConfiguration()
Get the underlyingConfiguration.
-
getBuiltInCatalogName
public String getBuiltInCatalogName()
Gets the specified name of the initial catalog to be created when instantiating aTableEnvironment.
-
getBuiltInDatabaseName
public String getBuiltInDatabaseName()
Gets the specified name of the default database in the initial catalog to be created when instantiating aTableEnvironment.
-
isStreamingMode
public boolean isStreamingMode()
Tells if theTableEnvironmentshould work in a batch or streaming mode.
-
getUserClassLoader
@Internal public ClassLoader getUserClassLoader()
Returns the userClassLoaderto use for code generation, UDF loading and other operations requiring reflections on user code.
-
getCatalogStore
@Internal @Nullable public org.apache.flink.table.catalog.CatalogStore getCatalogStore()
-
-