"Fossies" - the Fresh Open Source Software Archive 
Member "elasticsearch-6.8.23/x-pack/plugin/src/test/resources/rest-api-spec/test/deprecation/10_basic.yml" (29 Dec 2021, 1535 Bytes) of package /linux/www/elasticsearch-6.8.23-src.tar.gz:
As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) Ansible YAML source code syntax highlighting (style:
standard) with prefixed line numbers.
Alternatively you can here
view or
download the uninterpreted source code file.
1 ---
2 setup:
3 - do:
4 cluster.health:
5 wait_for_status: yellow
6
7 ---
8 "Test Deprecations":
9 - do:
10 xpack.migration.deprecations:
11 index: "*"
12 - length: { cluster_settings: 0 }
13 - length: { node_settings: 0 }
14 - length: { index_settings: 0 }
15 - length: { ml_settings: 0 }
16
17 ---
18 "Test ml":
19 - skip:
20 features: ["headers", "warnings"]
21 reason: testing a deprecated field
22
23 # Index the config directly to prevent the deprecated
24 # use_dis_max field being rewritten by the parser. This
25 # simulates the config being created in an older version
26 # of elasticsearch
27 - do:
28 headers:
29 Content-Type: application/json
30 index:
31 index: .ml-config
32 type: doc
33 id: deprecation-datafeed-datafeed
34 body: >
35 {
36 "datafeed_id" : "deprecation-datafeed",
37 "config_type" : "datafeed",
38 "job_id" : "deprecation-job",
39 "indices" : ["index-foo"],
40 "query" : {
41 "query_string" : {
42 "query" : "foo",
43 "use_dis_max" : true
44 }
45 }
46 }
47
48 - do:
49 indices.refresh:
50 index: [.ml-config]
51
52 - do:
53 warnings:
54 - Deprecated field [use_dis_max] used, replaced by [Set [tie_breaker] to 1 instead]
55 xpack.migration.deprecations:
56 index: "*"
57 - length: { ml_settings: 1 }
58 - match: { ml_settings.0.level : warning }
59 - match: { ml_settings.0.message : "Datafeed [deprecation-datafeed] uses deprecated query options" }