use of io.prestosql.plugin.hive.HivePushDownPageSource in project boostkit-bigdata by kunpengcompute.
the class ParquetPageSourceFactory method createParquetPushDownPageSource.
public HivePushDownPageSource createParquetPushDownPageSource(Path path, long start, long length, com.huawei.boostkit.omnidata.model.Predicate predicate) {
AggregatedMemoryContext systemMemoryUsage = newSimpleAggregatedMemoryContext();
Properties transProperties = new Properties();
transProperties.put(OMNIDATA_CLIENT_TARGET_LIST, omniDataServerTarget);
DataSource parquetPushDownDataSource = new com.huawei.boostkit.omnidata.model.datasource.hdfs.HdfsParquetDataSource(path.toString(), start, length, false);
TaskSource readTaskInfo = new TaskSource(parquetPushDownDataSource, predicate, TaskSource.ONE_MEGABYTES);
DataReader<Page> dataReader = DataReaderFactory.create(transProperties, readTaskInfo, new OpenLooKengDeserializer());
return new HivePushDownPageSource(dataReader, systemMemoryUsage);
}
use of io.prestosql.plugin.hive.HivePushDownPageSource in project boostkit-bigdata by kunpengcompute.
the class OrcPageSourceFactory method createOrcPushDownPageSource.
public HivePushDownPageSource createOrcPushDownPageSource(Path path, long start, long length, Predicate predicate) {
AggregatedMemoryContext systemMemoryUsage = newSimpleAggregatedMemoryContext();
Properties transProperties = new Properties();
transProperties.put(OMNIDATA_CLIENT_TARGET_LIST, omniDataServerTarget);
DataSource orcPushDownDataSource = new com.huawei.boostkit.omnidata.model.datasource.hdfs.HdfsOrcDataSource(path.toString(), start, length, false);
TaskSource readTaskInfo = new TaskSource(orcPushDownDataSource, predicate, TaskSource.ONE_MEGABYTES);
DataReader<Page> dataReader = DataReaderFactory.create(transProperties, readTaskInfo, new OpenLooKengDeserializer());
return new HivePushDownPageSource(dataReader, systemMemoryUsage);
}
Aggregations