[ML] Document test problem and make it slightly less likely
Relates elastic/x-pack-elasticsearch#689 This does NOT fix the problem, but makes it clearer why it happens and, by changing ordering, should make it happen less often Original commit: elastic/x-pack-elasticsearch@9ef60073c2
This commit is contained in:
parent
746eb2ead4
commit
2c365311af
|
@ -93,20 +93,19 @@ setup:
|
||||||
job_id: farequote2
|
job_id: farequote2
|
||||||
- match: { closed: true }
|
- match: { closed: true }
|
||||||
|
|
||||||
|
- do:
|
||||||
|
indices.exists:
|
||||||
|
index: ".ml-anomalies-farequote"
|
||||||
|
- is_true: ''
|
||||||
|
|
||||||
|
- do:
|
||||||
|
indices.exists:
|
||||||
|
index: ".ml-anomalies-farequote"
|
||||||
|
- is_true: ''
|
||||||
|
|
||||||
- do:
|
- do:
|
||||||
indices.refresh: {}
|
indices.refresh: {}
|
||||||
|
|
||||||
- do:
|
|
||||||
indices.exists:
|
|
||||||
index: ".ml-anomalies-farequote"
|
|
||||||
- is_true: ''
|
|
||||||
|
|
||||||
- do:
|
|
||||||
indices.exists:
|
|
||||||
index: ".ml-anomalies-farequote"
|
|
||||||
- is_true: ''
|
|
||||||
|
|
||||||
- do:
|
- do:
|
||||||
count:
|
count:
|
||||||
index: .ml-anomalies-shared
|
index: .ml-anomalies-shared
|
||||||
|
@ -164,14 +163,18 @@ setup:
|
||||||
job_id: "farequote"
|
job_id: "farequote"
|
||||||
- match: { acknowledged: true }
|
- match: { acknowledged: true }
|
||||||
|
|
||||||
- do:
|
# TODO: delete_job is asynchronous and returns before all job results are deleted - ideally
|
||||||
indices.refresh: {}
|
# we'd have a way to wait for delete_job to finish its work, but for now just assert some
|
||||||
|
# other things before refreshing the indexes to give time for delete_job to do its work
|
||||||
|
|
||||||
- do:
|
- do:
|
||||||
indices.exists:
|
indices.exists:
|
||||||
index: ".ml-anomalies-shared"
|
index: ".ml-anomalies-shared"
|
||||||
- is_true: ''
|
- is_true: ''
|
||||||
|
|
||||||
|
- do:
|
||||||
|
indices.refresh: {}
|
||||||
|
|
||||||
- do:
|
- do:
|
||||||
count:
|
count:
|
||||||
index: .ml-anomalies-shared
|
index: .ml-anomalies-shared
|
||||||
|
@ -218,8 +221,9 @@ setup:
|
||||||
job_id: "farequote2"
|
job_id: "farequote2"
|
||||||
- match: { acknowledged: true }
|
- match: { acknowledged: true }
|
||||||
|
|
||||||
- do:
|
# TODO: delete_job is asynchronous and returns before all job results are deleted - ideally
|
||||||
indices.refresh: {}
|
# we'd have a way to wait for delete_job to finish its work, but for now just assert some
|
||||||
|
# other things before refreshing the indexes to give time for delete_job to do its work
|
||||||
|
|
||||||
- do:
|
- do:
|
||||||
indices.exists:
|
indices.exists:
|
||||||
|
@ -236,6 +240,9 @@ setup:
|
||||||
index: ".ml-anomalies-farequote2"
|
index: ".ml-anomalies-farequote2"
|
||||||
- is_false: ''
|
- is_false: ''
|
||||||
|
|
||||||
|
- do:
|
||||||
|
indices.refresh: {}
|
||||||
|
|
||||||
- do:
|
- do:
|
||||||
count:
|
count:
|
||||||
index: .ml-anomalies-shared
|
index: .ml-anomalies-shared
|
||||||
|
@ -323,8 +330,27 @@ setup:
|
||||||
job_id: "farequote"
|
job_id: "farequote"
|
||||||
- match: { acknowledged: true }
|
- match: { acknowledged: true }
|
||||||
|
|
||||||
|
# TODO: delete_job is asynchronous and returns before all job results are deleted - ideally
|
||||||
|
# we'd have a way to wait for delete_job to finish its work, but for now just assert some
|
||||||
|
# other things before refreshing the indexes to give time for delete_job to do its work
|
||||||
|
|
||||||
- do:
|
- do:
|
||||||
indices.refresh: {}
|
indices.exists:
|
||||||
|
index: ".ml-anomalies-shared"
|
||||||
|
- is_true: ''
|
||||||
|
|
||||||
|
- do:
|
||||||
|
indices.exists:
|
||||||
|
index: ".ml-anomalies-foo"
|
||||||
|
- is_true: ''
|
||||||
|
|
||||||
|
- do:
|
||||||
|
indices.exists:
|
||||||
|
index: "foo"
|
||||||
|
- is_true: ''
|
||||||
|
|
||||||
|
- do:
|
||||||
|
indices.refresh: {}
|
||||||
|
|
||||||
- do:
|
- do:
|
||||||
count:
|
count:
|
||||||
|
@ -341,5 +367,3 @@ setup:
|
||||||
index: .ml-anomalies-foo
|
index: .ml-anomalies-foo
|
||||||
- match: {count: 2}
|
- match: {count: 2}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue