rest-api-spec.test.mlt.20_docs.yml Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of rest-api-spec Show documentation
Show all versions of rest-api-spec Show documentation
OpenSearch subproject :rest-api-spec
The newest version!
---
"Basic mlt query with docs":
- do:
indices.create:
index: test_1
body:
settings:
number_of_replicas: 0
- do:
index:
index: test_1
id: 1
body: { foo: bar }
- do:
index:
index: test_1
id: 2
body: { foo: baz }
- do:
index:
index: test_1
id: 3
body: { foo: foo }
- do:
indices.refresh: {}
- do:
cluster.health:
wait_for_status: green
- do:
search:
rest_total_hits_as_int: true
index: test_1
body:
query:
more_like_this:
like:
-
_index: test_1
doc:
foo: bar
-
_index: test_1
_id: 2
-
_id: 3
include: true
min_doc_freq: 0
min_term_freq: 0
- match: { hits.total: 3 }
© 2015 - 2024 Weber Informatics LLC | Privacy Policy