Search in sources :

Example 1 with TableMetadata

use of io.trino.plugin.raptor.legacy.metadata.TableMetadata in project trino by trinodb.

the class OrganizationJob method runJob.

private void runJob(long transactionId, OptionalInt bucketNumber, long tableId, Set<UUID> shardUuids) throws IOException {
    TableMetadata metadata = getTableMetadata(tableId);
    List<ShardInfo> newShards = performCompaction(transactionId, bucketNumber, shardUuids, metadata);
    log.info("Compacted shards %s into %s", shardUuids, newShards.stream().map(ShardInfo::getShardUuid).collect(toList()));
    shardManager.replaceShardUuids(transactionId, tableId, metadata.getColumns(), shardUuids, newShards, OptionalLong.empty());
}
Also used : TableMetadata(io.trino.plugin.raptor.legacy.metadata.TableMetadata) ShardInfo(io.trino.plugin.raptor.legacy.metadata.ShardInfo)

Aggregations

ShardInfo (io.trino.plugin.raptor.legacy.metadata.ShardInfo)1 TableMetadata (io.trino.plugin.raptor.legacy.metadata.TableMetadata)1