TableCatalog¶
TableCatalog
is an extension of the CatalogPlugin abstraction for table catalogs.
Contract¶
Altering Table¶
Table alterTable(
Identifier ident,
TableChange... changes)
Changes (alters) a table based on the given TableChanges
Used when:
- AlterTableExec physical command is executed
DelegatingCatalogExtension
is requested to alterTable
createTable¶
Table createTable(
Identifier ident,
Column[] columns,
Transform[] partitions,
Map<String, String> properties)
See:
Used when the following commands are executed:
CreateTableExec
ReplaceTableExec
- CreateTableAsSelectExec
ReplaceTableAsSelectExec
dropTable¶
boolean dropTable(
Identifier ident)
Used when the following commands are executed:
DropTableExec
ReplaceTableExec
- CreateTableAsSelectExec
ReplaceTableAsSelectExec
Listing Tables¶
Identifier[] listTables(
String[] namespace)
Used when the following commands are executed:
Loading Table¶
Table loadTable(
Identifier ident)
Table loadTable(
Identifier ident,
long timestamp)
Table loadTable(
Identifier ident,
String version)
Used when:
CatalogV2Util
is requested to load a tableDataFrameReader
is requested to load (for SupportsCatalogOptions providers)DataFrameWriter
is requested to save, insertInto and saveAsTableDelegatingCatalogExtension
is requested to loadTableTableCatalog
is requested to tableExistsV2SessionCatalog
is requested to createTable, alterTable, dropTable, renameTable
renameTable¶
void renameTable(
Identifier oldIdent,
Identifier newIdent)
Used when the following commands are executed:
RenameTableExec
tableExists¶
boolean tableExists(
Identifier ident)
Used when:
- The following commands are executed:
AtomicCreateTableAsSelectExec
AtomicReplaceTableAsSelectExec
AtomicReplaceTableExec
- CreateTableAsSelectExec
CreateTableExec
DropTableExec
ReplaceTableAsSelectExec
-
ReplaceTableExec
-
V2SessionCatalog
is requested to renameTable