From 8c21f2e53bfb6c22ffd528e8a483fd0bfaaf5fda Mon Sep 17 00:00:00 2001 From: wypb Date: Fri, 14 Feb 2025 15:39:14 +0800 Subject: [PATCH] [native] Add support for ORC reader and add orc native tests --- .../AbstractTestNativeTpcdsQueries.java | 106 +++++++++++++++ ...tiveIcebergTpcdsQueriesOrcUsingThrift.java | 128 ------------------ ...IcebergTpcdsQueriesParquetUsingThrift.java | 106 --------------- 3 files changed, 106 insertions(+), 234 deletions(-) diff --git a/presto-native-execution/src/test/java/com/facebook/presto/nativeworker/AbstractTestNativeTpcdsQueries.java b/presto-native-execution/src/test/java/com/facebook/presto/nativeworker/AbstractTestNativeTpcdsQueries.java index 57ee92b87a79..30a6a41786d3 100644 --- a/presto-native-execution/src/test/java/com/facebook/presto/nativeworker/AbstractTestNativeTpcdsQueries.java +++ b/presto-native-execution/src/test/java/com/facebook/presto/nativeworker/AbstractTestNativeTpcdsQueries.java @@ -1474,4 +1474,110 @@ protected void verifyDeletes() assertEquals(originalRowcount - postDeleteRowcount, numDeletedRows); } } + + protected void runAllQueries() throws Exception + { + testTpcdsQ1(); + testTpcdsQ2(); + testTpcdsQ3(); + testTpcdsQ4(); + testTpcdsQ5(); + testTpcdsQ6(); + testTpcdsQ7(); + testTpcdsQ8(); + testTpcdsQ9(); + testTpcdsQ10(); + testTpcdsQ11(); + testTpcdsQ12(); + testTpcdsQ13(); + testTpcdsQ14_1(); + testTpcdsQ14_2(); + testTpcdsQ15(); + testTpcdsQ16(); + testTpcdsQ17(); + testTpcdsQ18(); + testTpcdsQ19(); + testTpcdsQ20(); + testTpcdsQ21(); + testTpcdsQ22(); + testTpcdsQ23_1(); + testTpcdsQ23_2(); + testTpcdsQ24_1(); + testTpcdsQ24_2(); + testTpcdsQ25(); + testTpcdsQ26(); + testTpcdsQ27(); + testTpcdsQ28(); + testTpcdsQ29(); + testTpcdsQ30(); + testTpcdsQ31(); + testTpcdsQ32(); + testTpcdsQ33(); + testTpcdsQ34(); + testTpcdsQ35(); + testTpcdsQ36(); + testTpcdsQ37(); + testTpcdsQ38(); + testTpcdsQ39_1(); + testTpcdsQ39_2(); + testTpcdsQ40(); + testTpcdsQ41(); + testTpcdsQ42(); + testTpcdsQ43(); + testTpcdsQ44(); + testTpcdsQ45(); + testTpcdsQ46(); + testTpcdsQ47(); + testTpcdsQ48(); + testTpcdsQ49(); + testTpcdsQ50(); + testTpcdsQ51(); + testTpcdsQ52(); + testTpcdsQ53(); + testTpcdsQ54(); + testTpcdsQ55(); + testTpcdsQ56(); + testTpcdsQ57(); + testTpcdsQ58(); + testTpcdsQ59(); + testTpcdsQ60(); + testTpcdsQ61(); + testTpcdsQ62(); + testTpcdsQ63(); + testTpcdsQ65(); + testTpcdsQ66(); + testTpcdsQ67(); + testTpcdsQ68(); + testTpcdsQ69(); + testTpcdsQ70(); + testTpcdsQ71(); + testTpcdsQ72(); + testTpcdsQ73(); + testTpcdsQ74(); + testTpcdsQ75(); + testTpcdsQ76(); + testTpcdsQ77(); + testTpcdsQ78(); + testTpcdsQ79(); + testTpcdsQ80(); + testTpcdsQ81(); + testTpcdsQ82(); + testTpcdsQ83(); + testTpcdsQ84(); + testTpcdsQ85(); + testTpcdsQ86(); + testTpcdsQ87(); + testTpcdsQ88(); + testTpcdsQ89(); + testTpcdsQ90(); + testTpcdsQ91(); + testTpcdsQ92(); + testTpcdsQ93(); + testTpcdsQ94(); + testTpcdsQ95(); + testTpcdsQ96(); + testTpcdsQ97(); + testTpcdsQ98(); + testTpcdsQ99(); + } } diff --git a/presto-native-execution/src/test/java/com/facebook/presto/nativeworker/TestPrestoNativeIcebergTpcdsQueriesOrcUsingThrift.java b/presto-native-execution/src/test/java/com/facebook/presto/nativeworker/TestPrestoNativeIcebergTpcdsQueriesOrcUsingThrift.java index eb8e5e34dd11..3754e66aa8ea 100644 --- a/presto-native-execution/src/test/java/com/facebook/presto/nativeworker/TestPrestoNativeIcebergTpcdsQueriesOrcUsingThrift.java +++ b/presto-native-execution/src/test/java/com/facebook/presto/nativeworker/TestPrestoNativeIcebergTpcdsQueriesOrcUsingThrift.java @@ -37,134 +37,6 @@ protected ExpectedQueryRunner createExpectedQueryRunner() return PrestoNativeQueryRunnerUtils.createJavaIcebergQueryRunner("ORC"); } - protected void runAllQueries() throws Exception - { - testTpcdsQ1(); - testTpcdsQ2(); - testTpcdsQ3(); - testTpcdsQ4(); - testTpcdsQ5(); - testTpcdsQ6(); - testTpcdsQ7(); - testTpcdsQ8(); - testTpcdsQ9(); - testTpcdsQ10(); - testTpcdsQ11(); - testTpcdsQ12(); - testTpcdsQ13(); - testTpcdsQ14_1(); - testTpcdsQ14_2(); - testTpcdsQ15(); - testTpcdsQ16(); - testTpcdsQ17(); - testTpcdsQ18(); - testTpcdsQ19(); - testTpcdsQ20(); - // TODO After https://github.com/facebookincubator/velox/pull/11067 merged, - // we can enable this test for ORC. - // testTpcdsQ21(); - testTpcdsQ22(); - testTpcdsQ23_1(); - testTpcdsQ23_2(); - testTpcdsQ24_1(); - testTpcdsQ24_2(); - testTpcdsQ25(); - testTpcdsQ26(); - testTpcdsQ27(); - testTpcdsQ28(); - testTpcdsQ29(); - testTpcdsQ30(); - testTpcdsQ31(); - testTpcdsQ32(); - // TODO After https://github.com/facebookincubator/velox/pull/11067 merged, - // we can enable this test for ORC. - // testTpcdsQ33(); - testTpcdsQ34(); - testTpcdsQ35(); - testTpcdsQ36(); - // TODO After https://github.com/facebookincubator/velox/pull/11067 merged, - // we can enable this test for ORC. - // testTpcdsQ37(); - testTpcdsQ38(); - testTpcdsQ39_1(); - testTpcdsQ39_2(); - // TODO After https://github.com/facebookincubator/velox/pull/11067 merged, - // we can enable this test for ORC. - // testTpcdsQ40(); - testTpcdsQ41(); - testTpcdsQ42(); - // TODO After https://github.com/facebookincubator/velox/pull/11067 merged, - // we can enable this test for ORC. - // testTpcdsQ43(); - testTpcdsQ44(); - testTpcdsQ45(); - testTpcdsQ46(); - testTpcdsQ47(); - testTpcdsQ48(); - // TODO After https://github.com/facebookincubator/velox/pull/11067 merged, - // we can enable this test for ORC. - // testTpcdsQ49(); - testTpcdsQ50(); - testTpcdsQ51(); - testTpcdsQ52(); - testTpcdsQ53(); - testTpcdsQ54(); - testTpcdsQ55(); - // TODO After https://github.com/facebookincubator/velox/pull/11067 merged, - // we can enable this test for ORC. - // testTpcdsQ56(); - testTpcdsQ57(); - testTpcdsQ58(); - testTpcdsQ59(); - // TODO After https://github.com/facebookincubator/velox/pull/11067 merged, - // we can enable this test for ORC. - // testTpcdsQ60(); - // testTpcdsQ61(); - testTpcdsQ62(); - testTpcdsQ63(); - testTpcdsQ65(); - testTpcdsQ66(); - testTpcdsQ67(); - testTpcdsQ68(); - testTpcdsQ69(); - testTpcdsQ70(); - testTpcdsQ71(); - testTpcdsQ72(); - testTpcdsQ73(); - testTpcdsQ74(); - testTpcdsQ75(); - testTpcdsQ76(); - testTpcdsQ77(); - testTpcdsQ78(); - testTpcdsQ79(); - // TODO After https://github.com/facebookincubator/velox/pull/11067 merged, - // we can enable this test for ORC. - // testTpcdsQ80(); - testTpcdsQ81(); - // TODO After https://github.com/facebookincubator/velox/pull/11067 merged, - // we can enable this test for ORC. - // testTpcdsQ82(); - testTpcdsQ83(); - testTpcdsQ84(); - testTpcdsQ85(); - testTpcdsQ86(); - testTpcdsQ87(); - testTpcdsQ88(); - testTpcdsQ89(); - testTpcdsQ90(); - // TODO After https://github.com/facebookincubator/velox/pull/11067 merged, - // we can enable this test for ORC. - // testTpcdsQ91(); - testTpcdsQ92(); - testTpcdsQ93(); - testTpcdsQ94(); - testTpcdsQ95(); - testTpcdsQ96(); - testTpcdsQ97(); - testTpcdsQ98(); - testTpcdsQ99(); - } - @Test public void doDeletesAndQuery() throws Exception { diff --git a/presto-native-execution/src/test/java/com/facebook/presto/nativeworker/TestPrestoNativeIcebergTpcdsQueriesParquetUsingThrift.java b/presto-native-execution/src/test/java/com/facebook/presto/nativeworker/TestPrestoNativeIcebergTpcdsQueriesParquetUsingThrift.java index 7567c5c24806..297cc05ce6dd 100644 --- a/presto-native-execution/src/test/java/com/facebook/presto/nativeworker/TestPrestoNativeIcebergTpcdsQueriesParquetUsingThrift.java +++ b/presto-native-execution/src/test/java/com/facebook/presto/nativeworker/TestPrestoNativeIcebergTpcdsQueriesParquetUsingThrift.java @@ -37,112 +37,6 @@ protected ExpectedQueryRunner createExpectedQueryRunner() return PrestoNativeQueryRunnerUtils.createJavaIcebergQueryRunner("PARQUET"); } - protected void runAllQueries() throws Exception - { - testTpcdsQ1(); - testTpcdsQ2(); - testTpcdsQ3(); - testTpcdsQ4(); - testTpcdsQ5(); - testTpcdsQ6(); - testTpcdsQ7(); - testTpcdsQ8(); - testTpcdsQ9(); - testTpcdsQ10(); - testTpcdsQ11(); - testTpcdsQ12(); - testTpcdsQ13(); - testTpcdsQ14_1(); - testTpcdsQ14_2(); - testTpcdsQ15(); - testTpcdsQ16(); - testTpcdsQ17(); - testTpcdsQ18(); - testTpcdsQ19(); - testTpcdsQ20(); - testTpcdsQ21(); - testTpcdsQ22(); - testTpcdsQ23_1(); - testTpcdsQ23_2(); - testTpcdsQ24_1(); - testTpcdsQ24_2(); - testTpcdsQ25(); - testTpcdsQ26(); - testTpcdsQ27(); - testTpcdsQ28(); - testTpcdsQ29(); - testTpcdsQ30(); - testTpcdsQ31(); - testTpcdsQ32(); - testTpcdsQ33(); - testTpcdsQ34(); - testTpcdsQ35(); - testTpcdsQ36(); - testTpcdsQ37(); - testTpcdsQ38(); - testTpcdsQ39_1(); - testTpcdsQ39_2(); - testTpcdsQ40(); - testTpcdsQ41(); - testTpcdsQ42(); - testTpcdsQ43(); - testTpcdsQ44(); - testTpcdsQ45(); - testTpcdsQ46(); - testTpcdsQ47(); - testTpcdsQ48(); - testTpcdsQ49(); - testTpcdsQ50(); - testTpcdsQ51(); - testTpcdsQ52(); - testTpcdsQ53(); - testTpcdsQ54(); - testTpcdsQ55(); - testTpcdsQ56(); - testTpcdsQ57(); - testTpcdsQ58(); - testTpcdsQ59(); - testTpcdsQ60(); - testTpcdsQ61(); - testTpcdsQ62(); - testTpcdsQ63(); - testTpcdsQ65(); - testTpcdsQ66(); - testTpcdsQ67(); - testTpcdsQ68(); - testTpcdsQ69(); - testTpcdsQ70(); - testTpcdsQ71(); - testTpcdsQ72(); - testTpcdsQ73(); - testTpcdsQ74(); - testTpcdsQ75(); - testTpcdsQ76(); - testTpcdsQ77(); - testTpcdsQ78(); - testTpcdsQ79(); - testTpcdsQ80(); - testTpcdsQ81(); - testTpcdsQ82(); - testTpcdsQ83(); - testTpcdsQ84(); - testTpcdsQ85(); - testTpcdsQ86(); - testTpcdsQ87(); - testTpcdsQ88(); - testTpcdsQ89(); - testTpcdsQ90(); - testTpcdsQ91(); - testTpcdsQ92(); - testTpcdsQ93(); - testTpcdsQ94(); - testTpcdsQ95(); - testTpcdsQ96(); - testTpcdsQ97(); - testTpcdsQ98(); - testTpcdsQ99(); - } - @Test public void doDeletesAndQuery() throws Exception {