Skip to content

Commit 6b0254b

Browse files
committed
Ignore q30 when GCedMemoryUsage not initialized
Signed-off-by: Lantao Jin <ltjin@amazon.com>
1 parent 32d8fa7 commit 6b0254b

1 file changed

Lines changed: 9 additions & 3 deletions

File tree

integ-test/src/test/java/org/opensearch/sql/calcite/clickbench/PPLClickBenchIT.java

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
import org.junit.Test;
1515
import org.junit.runners.MethodSorters;
1616
import org.opensearch.common.collect.MapBuilder;
17+
import org.opensearch.sql.opensearch.monitor.GCedMemoryUsage;
1718
import org.opensearch.sql.ppl.PPLIntegTestCase;
1819

1920
@FixMethodOrder(MethodSorters.JVM)
@@ -49,11 +50,16 @@ public static void reset() throws IOException {
4950
}
5051

5152
/**
52-
* Ignore queries that are not supported by Calcite. Ignore q30 because of too much script push
53-
* down, which will cause ResourceMonitor restriction.
53+
* Ignore queries that are not supported by Calcite.
5454
*/
5555
protected Set<Integer> ignored() {
56-
return Set.of(29);
56+
if (GCedMemoryUsage.initialized()) {
57+
return Set.of(29);
58+
} else {
59+
// Ignore q30 when use RuntimeMemoryUsage,
60+
// because of too much script push down, which will cause ResourceMonitor restriction.
61+
return Set.of(29, 30);
62+
}
5763
}
5864

5965
@Test

0 commit comments

Comments
 (0)