use of io.trino.plugin.hive.AcidInfo in project trino by trinodb.
the class TestOrcPageSourceFactory method testReadWithAcidVersionValidationHive3.
@Test
public void testReadWithAcidVersionValidationHive3() throws Exception {
File tableFile = new File(getResource("acid_version_validation/acid_version_hive_3/00000_0").toURI());
String tablePath = tableFile.getParent();
Optional<AcidInfo> acidInfo = AcidInfo.builder(new Path(tablePath)).setOrcAcidVersionValidated(false).build();
List<Nation> result = readFile(Map.of(), OptionalLong.empty(), acidInfo, tableFile.getPath(), 625);
assertEquals(result.size(), 1);
}
use of io.trino.plugin.hive.AcidInfo in project trino by trinodb.
the class TestOrcPageSourceFactory method testDeletedRows.
@Test
public void testDeletedRows() {
Path partitionLocation = new Path(getClass().getClassLoader().getResource("nation_delete_deltas") + "/");
Optional<AcidInfo> acidInfo = AcidInfo.builder(partitionLocation).addDeleteDelta(new Path(partitionLocation, deleteDeltaSubdir(3L, 3L, 0))).addDeleteDelta(new Path(partitionLocation, deleteDeltaSubdir(4L, 4L, 0))).build();
assertRead(ALL_COLUMNS, OptionalLong.empty(), acidInfo, nationKey -> nationKey == 5 || nationKey == 19);
}
Aggregations