public class FlinkCatalogFactory
extends java.lang.Object
implements org.apache.flink.table.factories.CatalogFactory
FlinkCatalog
.
This supports the following catalog configuration options:
type
- Flink catalog factory key, should be "iceberg"
catalog-type
- iceberg catalog type, "hive", "hadoop" or "rest"
uri
- the Hive Metastore URI (Hive catalog only)
clients
- the Hive Client Pool Size (Hive catalog only)
warehouse
- the warehouse path (Hadoop catalog only)
default-database
- a database name to use as the default
base-namespace
- a base namespace as the prefix for all databases (Hadoop
catalog only)
cache-enabled
- whether to enable catalog cache
To use a custom catalog that is not a Hive or Hadoop catalog, extend this class and override
createCatalogLoader(String, Map, Configuration)
.
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
BASE_NAMESPACE |
static java.lang.String |
DEFAULT_DATABASE |
static java.lang.String |
DEFAULT_DATABASE_NAME |
static java.lang.String |
HADOOP_CONF_DIR |
static java.lang.String |
HIVE_CONF_DIR |
static java.lang.String |
ICEBERG_CATALOG_TYPE |
static java.lang.String |
ICEBERG_CATALOG_TYPE_HADOOP |
static java.lang.String |
ICEBERG_CATALOG_TYPE_HIVE |
static java.lang.String |
ICEBERG_CATALOG_TYPE_REST |
static java.lang.String |
PROPERTY_VERSION |
static java.lang.String |
TYPE |
Constructor and Description |
---|
FlinkCatalogFactory() |
Modifier and Type | Method and Description |
---|---|
static org.apache.hadoop.conf.Configuration |
clusterHadoopConf() |
org.apache.flink.table.catalog.Catalog |
createCatalog(java.lang.String name,
java.util.Map<java.lang.String,java.lang.String> properties) |
protected org.apache.flink.table.catalog.Catalog |
createCatalog(java.lang.String name,
java.util.Map<java.lang.String,java.lang.String> properties,
org.apache.hadoop.conf.Configuration hadoopConf) |
java.util.Map<java.lang.String,java.lang.String> |
requiredContext() |
java.util.List<java.lang.String> |
supportedProperties() |
public static final java.lang.String ICEBERG_CATALOG_TYPE
public static final java.lang.String ICEBERG_CATALOG_TYPE_HADOOP
public static final java.lang.String ICEBERG_CATALOG_TYPE_HIVE
public static final java.lang.String ICEBERG_CATALOG_TYPE_REST
public static final java.lang.String HIVE_CONF_DIR
public static final java.lang.String HADOOP_CONF_DIR
public static final java.lang.String DEFAULT_DATABASE
public static final java.lang.String DEFAULT_DATABASE_NAME
public static final java.lang.String BASE_NAMESPACE
public static final java.lang.String TYPE
public static final java.lang.String PROPERTY_VERSION
public java.util.Map<java.lang.String,java.lang.String> requiredContext()
requiredContext
in interface org.apache.flink.table.factories.CatalogFactory
requiredContext
in interface org.apache.flink.table.factories.TableFactory
public java.util.List<java.lang.String> supportedProperties()
supportedProperties
in interface org.apache.flink.table.factories.CatalogFactory
supportedProperties
in interface org.apache.flink.table.factories.TableFactory
public org.apache.flink.table.catalog.Catalog createCatalog(java.lang.String name, java.util.Map<java.lang.String,java.lang.String> properties)
createCatalog
in interface org.apache.flink.table.factories.CatalogFactory
protected org.apache.flink.table.catalog.Catalog createCatalog(java.lang.String name, java.util.Map<java.lang.String,java.lang.String> properties, org.apache.hadoop.conf.Configuration hadoopConf)
public static org.apache.hadoop.conf.Configuration clusterHadoopConf()