Package org.apache.iceberg.gcp.bigquery
Class BigQueryMetastoreCatalog
java.lang.Object
org.apache.iceberg.BaseMetastoreCatalog
org.apache.iceberg.gcp.bigquery.BigQueryMetastoreCatalog
- All Implemented Interfaces:
Closeable,AutoCloseable,org.apache.iceberg.catalog.Catalog,org.apache.iceberg.catalog.SupportsNamespaces,org.apache.iceberg.hadoop.Configurable<Object>
public class BigQueryMetastoreCatalog
extends org.apache.iceberg.BaseMetastoreCatalog
implements org.apache.iceberg.catalog.SupportsNamespaces, org.apache.iceberg.hadoop.Configurable<Object>
Iceberg Bigquery Metastore Catalog implementation.
-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.iceberg.BaseMetastoreCatalog
org.apache.iceberg.BaseMetastoreCatalog.BaseMetastoreCatalogTableBuilderNested classes/interfaces inherited from interface org.apache.iceberg.catalog.Catalog
org.apache.iceberg.catalog.Catalog.TableBuilder -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringDeprecated.static final StringDeprecated.since 1.11.0, will be removed in 1.12.0; useBigQueryProperties.LIST_ALL_TABLESinstead.static final StringDeprecated.since 1.11.0, will be removed in 1.12.0; useBigQueryProperties.PROJECT_IDinstead. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidcreateNamespace(org.apache.iceberg.catalog.Namespace namespace, Map<String, String> metadata) protected StringdefaultWarehouseLocation(org.apache.iceberg.catalog.TableIdentifier identifier) booleandropNamespace(org.apache.iceberg.catalog.Namespace namespace) booleandropTable(org.apache.iceberg.catalog.TableIdentifier identifier, boolean purge) voidinitialize(String name, Map<String, String> properties) protected booleanisValidIdentifier(org.apache.iceberg.catalog.TableIdentifier identifier) List<org.apache.iceberg.catalog.Namespace>List<org.apache.iceberg.catalog.Namespace>listNamespaces(org.apache.iceberg.catalog.Namespace namespace) Since this catalog only supports one-level namespaces, it always returns an empty list unless passed an empty namespace to list all namespaces within the catalog.List<org.apache.iceberg.catalog.TableIdentifier>listTables(org.apache.iceberg.catalog.Namespace namespace) loadNamespaceMetadata(org.apache.iceberg.catalog.Namespace namespace) name()protected org.apache.iceberg.TableOperationsnewTableOps(org.apache.iceberg.catalog.TableIdentifier identifier) booleanremoveProperties(org.apache.iceberg.catalog.Namespace namespace, Set<String> properties) voidrenameTable(org.apache.iceberg.catalog.TableIdentifier from, org.apache.iceberg.catalog.TableIdentifier to) voidbooleansetProperties(org.apache.iceberg.catalog.Namespace namespace, Map<String, String> properties) Methods inherited from class org.apache.iceberg.BaseMetastoreCatalog
buildTable, close, fullTableName, isValidMetadataIdentifier, loadTable, metricsReporter, registerTable, toStringMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.apache.iceberg.catalog.Catalog
createTable, createTable, createTable, createTable, dropTable, invalidateTable, newCreateTableTransaction, newCreateTableTransaction, newCreateTableTransaction, newCreateTableTransaction, newReplaceTableTransaction, newReplaceTableTransaction, newReplaceTableTransaction, newReplaceTableTransaction, registerTable, tableExistsMethods inherited from interface org.apache.iceberg.catalog.SupportsNamespaces
createNamespace, namespaceExists
-
Field Details
-
PROJECT_ID
Deprecated.since 1.11.0, will be removed in 1.12.0; useBigQueryProperties.PROJECT_IDinstead.- See Also:
-
GCP_LOCATION
Deprecated.since 1.11.0, will be removed in 1.12.0; useBigQueryProperties.GCP_LOCATIONinstead.- See Also:
-
LIST_ALL_TABLES
Deprecated.since 1.11.0, will be removed in 1.12.0; useBigQueryProperties.LIST_ALL_TABLESinstead.- See Also:
-
-
Constructor Details
-
BigQueryMetastoreCatalog
public BigQueryMetastoreCatalog()
-
-
Method Details
-
initialize
- Specified by:
initializein interfaceorg.apache.iceberg.catalog.Catalog
-
newTableOps
protected org.apache.iceberg.TableOperations newTableOps(org.apache.iceberg.catalog.TableIdentifier identifier) - Specified by:
newTableOpsin classorg.apache.iceberg.BaseMetastoreCatalog
-
defaultWarehouseLocation
- Specified by:
defaultWarehouseLocationin classorg.apache.iceberg.BaseMetastoreCatalog
-
listTables
public List<org.apache.iceberg.catalog.TableIdentifier> listTables(org.apache.iceberg.catalog.Namespace namespace) - Specified by:
listTablesin interfaceorg.apache.iceberg.catalog.Catalog
-
dropTable
public boolean dropTable(org.apache.iceberg.catalog.TableIdentifier identifier, boolean purge) - Specified by:
dropTablein interfaceorg.apache.iceberg.catalog.Catalog
-
renameTable
public void renameTable(org.apache.iceberg.catalog.TableIdentifier from, org.apache.iceberg.catalog.TableIdentifier to) - Specified by:
renameTablein interfaceorg.apache.iceberg.catalog.Catalog
-
createNamespace
public void createNamespace(org.apache.iceberg.catalog.Namespace namespace, Map<String, String> metadata) - Specified by:
createNamespacein interfaceorg.apache.iceberg.catalog.SupportsNamespaces
-
listNamespaces
- Specified by:
listNamespacesin interfaceorg.apache.iceberg.catalog.SupportsNamespaces
-
listNamespaces
public List<org.apache.iceberg.catalog.Namespace> listNamespaces(org.apache.iceberg.catalog.Namespace namespace) Since this catalog only supports one-level namespaces, it always returns an empty list unless passed an empty namespace to list all namespaces within the catalog.- Specified by:
listNamespacesin interfaceorg.apache.iceberg.catalog.SupportsNamespaces
-
dropNamespace
public boolean dropNamespace(org.apache.iceberg.catalog.Namespace namespace) - Specified by:
dropNamespacein interfaceorg.apache.iceberg.catalog.SupportsNamespaces
-
setProperties
public boolean setProperties(org.apache.iceberg.catalog.Namespace namespace, Map<String, String> properties) - Specified by:
setPropertiesin interfaceorg.apache.iceberg.catalog.SupportsNamespaces
-
removeProperties
public boolean removeProperties(org.apache.iceberg.catalog.Namespace namespace, Set<String> properties) - Specified by:
removePropertiesin interfaceorg.apache.iceberg.catalog.SupportsNamespaces
-
loadNamespaceMetadata
- Specified by:
loadNamespaceMetadatain interfaceorg.apache.iceberg.catalog.SupportsNamespaces
-
isValidIdentifier
protected boolean isValidIdentifier(org.apache.iceberg.catalog.TableIdentifier identifier) - Overrides:
isValidIdentifierin classorg.apache.iceberg.BaseMetastoreCatalog
-
name
- Specified by:
namein interfaceorg.apache.iceberg.catalog.Catalog
-
properties
- Overrides:
propertiesin classorg.apache.iceberg.BaseMetastoreCatalog
-
setConf
- Specified by:
setConfin interfaceorg.apache.iceberg.hadoop.Configurable<Object>
-
BigQueryProperties.GCP_LOCATIONinstead.