use of com.facebook.presto.connector.ConnectorId in project presto by prestodb.
the class MetadataManager method beginDelete.
@Override
public TableHandle beginDelete(Session session, TableHandle tableHandle) {
ConnectorId connectorId = tableHandle.getConnectorId();
ConnectorMetadata metadata = getMetadataForWrite(session, connectorId);
ConnectorTableHandle newHandle = metadata.beginDelete(session.toConnectorSession(connectorId), tableHandle.getConnectorHandle());
return new TableHandle(tableHandle.getConnectorId(), newHandle);
}
use of com.facebook.presto.connector.ConnectorId in project presto by prestodb.
the class MetadataManager method dropSchema.
@Override
public void dropSchema(Session session, CatalogSchemaName schema) {
CatalogMetadata catalogMetadata = getCatalogMetadataForWrite(session, schema.getCatalogName());
ConnectorId connectorId = catalogMetadata.getConnectorId();
ConnectorMetadata metadata = catalogMetadata.getMetadata();
metadata.dropSchema(session.toConnectorSession(connectorId), schema.getSchemaName());
}
use of com.facebook.presto.connector.ConnectorId in project presto by prestodb.
the class MetadataManager method getTableMetadata.
@Override
public TableMetadata getTableMetadata(Session session, TableHandle tableHandle) {
ConnectorId connectorId = tableHandle.getConnectorId();
ConnectorMetadata metadata = getMetadata(session, connectorId);
ConnectorTableMetadata tableMetadata = metadata.getTableMetadata(session.toConnectorSession(connectorId), tableHandle.getConnectorHandle());
return new TableMetadata(connectorId, tableMetadata);
}
use of com.facebook.presto.connector.ConnectorId in project presto by prestodb.
the class MetadataManager method finishDelete.
@Override
public void finishDelete(Session session, TableHandle tableHandle, Collection<Slice> fragments) {
ConnectorId connectorId = tableHandle.getConnectorId();
ConnectorMetadata metadata = getMetadata(session, connectorId);
metadata.finishDelete(session.toConnectorSession(connectorId), tableHandle.getConnectorHandle(), fragments);
}
use of com.facebook.presto.connector.ConnectorId in project presto by prestodb.
the class MetadataManager method dropTable.
@Override
public void dropTable(Session session, TableHandle tableHandle) {
ConnectorId connectorId = tableHandle.getConnectorId();
ConnectorMetadata metadata = getMetadataForWrite(session, connectorId);
metadata.dropTable(session.toConnectorSession(connectorId), tableHandle.getConnectorHandle());
}
Aggregations