File tree 1 file changed +73
-0
lines changed
x-pack/plugin/rollup/qa/rest/src/yamlRestTest/resources/rest-api-spec/test/rollup 1 file changed +73
-0
lines changed Original file line number Diff line number Diff line change @@ -146,6 +146,15 @@ setup:
146
146
indices.get :
147
147
index : test
148
148
149
+ # Assert rollup index has been force merged
150
+ - do :
151
+ indices.segments :
152
+ index : rollup-test
153
+
154
+ - match : { _shards.total: 1}
155
+ - match : { indices.rollup-test.shards.0.0.num_committed_segments: 1}
156
+ - match : { indices.rollup-test.shards.0.0.num_search_segments: 1}
157
+
149
158
---
150
159
" Rollup non-existing index " :
151
160
- skip :
@@ -181,3 +190,67 @@ setup:
181
190
{
182
191
"fixed_interval": "1h"
183
192
}
193
+
194
+ ---
195
+ " Rollup not time_series index " :
196
+ - skip :
197
+ version : " - 8.4.99"
198
+ reason : " rollup renamed to downsample in 8.5.0"
199
+
200
+ - do :
201
+ indices.create :
202
+ index : normal-index
203
+
204
+ - do :
205
+ catch : /Rollup requires setting \[index.mode=time_series\] for index \[normal-index\]/
206
+ indices.downsample :
207
+ index : normal-index
208
+ target_index : rollup-test
209
+ body : >
210
+ {
211
+ "fixed_interval": "1h"
212
+ }
213
+
214
+
215
+ ---
216
+ " Rollup no metric index " :
217
+ - skip :
218
+ version : " - 8.4.99"
219
+ reason : " rollup renamed to downsample in 8.5.0"
220
+
221
+ - do :
222
+ indices.create :
223
+ index : no-metric-index
224
+ body :
225
+ settings :
226
+ number_of_shards : 1
227
+ number_of_replicas : 0
228
+ index :
229
+ mode : time_series
230
+ routing_path : [metricset]
231
+ time_series :
232
+ start_time : 2021-04-28T00:00:00Z
233
+ end_time : 2021-04-29T00:00:00Z
234
+ mappings :
235
+ properties :
236
+ " @timestamp " :
237
+ type : date
238
+ metricset :
239
+ type : keyword
240
+ time_series_dimension : true
241
+
242
+ - do :
243
+ indices.put_settings :
244
+ index : no-metric-index
245
+ body :
246
+ index.blocks.write : true
247
+
248
+ - do :
249
+ catch : /Index \[no-metric-index\] does not contain any metric fields;/
250
+ indices.downsample :
251
+ index : no-metric-index
252
+ target_index : rollup-test
253
+ body : >
254
+ {
255
+ "fixed_interval": "1h"
256
+ }
You can’t perform that action at this time.
0 commit comments