use of io.prestosql.spi.connector.ConnectorUpdateTableHandle in project hetu-core by openlookeng.
the class MetadataManager method beginUpdateAsInsert.
@Override
public UpdateTableHandle beginUpdateAsInsert(Session session, TableHandle tableHandle) {
CatalogName catalogName = tableHandle.getCatalogName();
CatalogMetadata catalogMetadata = getCatalogMetadataForWrite(session, catalogName);
ConnectorMetadata metadata = catalogMetadata.getMetadata();
ConnectorTransactionHandle transactionHandle = catalogMetadata.getTransactionHandleFor(catalogName);
ConnectorUpdateTableHandle handle = metadata.beginUpdateAsInsert(session.toConnectorSession(catalogName), tableHandle.getConnectorHandle());
return new UpdateTableHandle(tableHandle.getCatalogName(), transactionHandle, handle);
}
Aggregations