Commit 9ccd9d8
committed
Stabilize CalcitePPLConditionBuiltinFunctionIT on the analytics-engine route
init() seeds two extra docs into state_country_with_null via unconditional
raw PUTs. init() runs as @before before every test method, and the
analytics-engine parquet-backed store is append-only on same-_id PUT, so the
docs accumulated a duplicate per method and inflated row counts across the
suite. Guard the seed on a pre-loadIndex isIndexExist check so it runs exactly
once; behavior is unchanged on the v2/Calcite route (same end state).
Skip the six tests that exercise behaviors the analytics-engine route does not
support, using the assumeNotAnalytics(...) registry (AnalyticsRouteLimitation)
plus matching excludeTestsMatching entries in integTestRemote so the skip set
stays countable in one place. NESTED_FIELDS is reused; three new constants:
- STRUCT_PARENT_FIELD: querying an object/struct parent field directly
(isnull/isnotnull(aws)) resolves to FIELD_NOT_FOUND — the route flattens
objects to dotted leaf columns and the parent is not a queryable column.
- CONCAT_NULL_AS_EMPTY: concat('H', null) = 'H' on the route (DataFusion
NULL-as-empty) vs null on v2/Calcite (NULL-propagating).
- EARLIEST_LATEST_NOW_CLOCK: earliest('now', utc_timestamp()) is true on the
route (same instant) but false on v2 (clock-source divergence).
The two nested tests reuse NESTED_FIELDS (nested fields are stripped at index
creation on this route, #5541).
Results (-Dtests.analytics.parquet_indices=true against the analytics route):
CalcitePPLConditionBuiltinFunctionIT: 6/24 -> 18/18 run, 0 fail (6 excluded)
v2/Calcite route unchanged: 24/24 pass.
Signed-off-by: Kai Huang <ahkcs@amazon.com>1 parent 9663d5f commit 9ccd9d8
3 files changed
Lines changed: 88 additions & 12 deletions
File tree
- integ-test
- src/test/java/org/opensearch/sql
- calcite/remote
- util
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1135 | 1135 | | |
1136 | 1136 | | |
1137 | 1137 | | |
| 1138 | + | |
| 1139 | + | |
| 1140 | + | |
| 1141 | + | |
| 1142 | + | |
| 1143 | + | |
| 1144 | + | |
| 1145 | + | |
| 1146 | + | |
| 1147 | + | |
| 1148 | + | |
| 1149 | + | |
| 1150 | + | |
| 1151 | + | |
| 1152 | + | |
| 1153 | + | |
| 1154 | + | |
1138 | 1155 | | |
1139 | 1156 | | |
1140 | 1157 | | |
| |||
Lines changed: 35 additions & 11 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
| 8 | + | |
8 | 9 | | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
9 | 14 | | |
10 | 15 | | |
11 | 16 | | |
| |||
22 | 27 | | |
23 | 28 | | |
24 | 29 | | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
25 | 35 | | |
26 | 36 | | |
27 | 37 | | |
28 | 38 | | |
29 | 39 | | |
30 | | - | |
31 | | - | |
32 | | - | |
33 | | - | |
34 | | - | |
35 | | - | |
36 | | - | |
37 | | - | |
38 | | - | |
39 | | - | |
40 | | - | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
41 | 53 | | |
42 | 54 | | |
43 | 55 | | |
| |||
54 | 66 | | |
55 | 67 | | |
56 | 68 | | |
| 69 | + | |
| 70 | + | |
57 | 71 | | |
58 | 72 | | |
59 | 73 | | |
60 | 74 | | |
61 | 75 | | |
62 | 76 | | |
63 | 77 | | |
| 78 | + | |
| 79 | + | |
64 | 80 | | |
65 | 81 | | |
66 | 82 | | |
| |||
124 | 140 | | |
125 | 141 | | |
126 | 142 | | |
| 143 | + | |
| 144 | + | |
127 | 145 | | |
128 | 146 | | |
129 | 147 | | |
130 | 148 | | |
131 | 149 | | |
132 | 150 | | |
133 | 151 | | |
| 152 | + | |
| 153 | + | |
134 | 154 | | |
135 | 155 | | |
136 | 156 | | |
| |||
165 | 185 | | |
166 | 186 | | |
167 | 187 | | |
| 188 | + | |
| 189 | + | |
168 | 190 | | |
169 | 191 | | |
170 | 192 | | |
| |||
354 | 376 | | |
355 | 377 | | |
356 | 378 | | |
| 379 | + | |
| 380 | + | |
357 | 381 | | |
358 | 382 | | |
359 | 383 | | |
| |||
Lines changed: 36 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
108 | 108 | | |
109 | 109 | | |
110 | 110 | | |
111 | | - | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
112 | 147 | | |
113 | 148 | | |
114 | 149 | | |
| |||
0 commit comments