Skip to content

Commit

Permalink
renaming folders, using multiple methods, deleting default code
Browse files Browse the repository at this point in the history
Signed-off-by: Tokesh <[email protected]>
  • Loading branch information
Tokesh committed Dec 17, 2024
1 parent b377b37 commit 7effb63
Show file tree
Hide file tree
Showing 5 changed files with 23 additions and 91 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
- Added response schema for `PUT` and `DELETE /_plugins/_transform/{id}` ([#722](https://github.com/opensearch-project/opensearch-api-specification/pull/716))
- Added response schema for `GET /_plugins/_knn/warmup/{index}` ([#717](https://github.com/opensearch-project/opensearch-api-specification/pull/717))
- Added support for multiple test verbs ([#724](https://github.com/opensearch-project/opensearch-api-specification/pull/724))
- Added string type in additionalProperties to `msearch template` ([#735](https://github.com/opensearch-project/opensearch-api-specification/pull/735))

### Removed
- Removed unsupported `_common.mapping:SourceField`'s `mode` field and associated `_common.mapping:SourceFieldMode` enum ([#652](https://github.com/opensearch-project/opensearch-api-specification/pull/652))
Expand Down Expand Up @@ -70,6 +69,7 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/)
- Fixed response schema for `/_render/template` and `/_render/template/{id}` ([#724](https://github.com/opensearch-project/opensearch-api-specification/pull/724))
- Fixed data stream schema numeric property types ([#725](https://github.com/opensearch-project/opensearch-api-specification/pull/725))
- Fixed snapshot status numeric property types ([#729](https://github.com/opensearch-project/opensearch-api-specification/pull/729))
- Fixed type in `_msearch/template` ([#735](https://github.com/opensearch-project/opensearch-api-specification/pull/735))

### Changed
- Changed `tasks._common:TaskInfo` and `tasks._common:TaskGroup` to be composed of a `tasks._common:TaskInfoBase` ([#683](https://github.com/opensearch-project/opensearch-api-specification/pull/683))
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
$schema: ../../../json_schemas/test_story.schema.yaml
$schema: ../../../../json_schemas/test_story.schema.yaml

description: Test document multi-search.
epilogues:
Expand All @@ -25,7 +25,9 @@ prologues:
chapters:
- synopsis: Run multiple search requests in single request (GET).
path: /_msearch
method: GET
method:
- GET
- POST
request:
content_type: application/x-ndjson
payload:
Expand All @@ -52,34 +54,4 @@ chapters:
- _index: movies
_id: movie1
- _index: movies
_id: movie2
- synopsis: Run multiple search requests in single request (POST).
path: /_msearch
method: POST
request:
content_type: application/x-ndjson
payload:
- {index: movies}
- {query: {match_all: {}}}
- {index: books}
- {query: {match_all: {}}}
response:
status: 200
payload:
responses:
- hits:
total:
value: 2
relation: eq
hits:
- _index: movies
_id: movie1
- _index: movies
_id: movie2
- hits:
total:
value: 1
relation: eq
hits:
- _index: books
_id: book1
_id: movie2
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
$schema: ../../../json_schemas/test_story.schema.yaml
$schema: ../../../../json_schemas/test_story.schema.yaml

description: Test _termvectors and _msearch/template APIs.
description: Test _msearch/template APIs.
prologues:
- path: /_bulk
method: POST
Expand All @@ -23,25 +23,13 @@ epilogues:
chapters:
- synopsis: Perform a multi-search template query using a GET request.
path: /_msearch/template
method: GET
method:
- GET
- POST
request:
content_type: application/x-ndjson
payload:
- {index: books}
- {source: '{"query": {"match": {"title": "{{title}}"}}}', params: {title: Mockingbird}}
- {index: books}
- {source: '{"query": {"match": {"title": "{{title}}"}}}', params: {title: Beast}}
response:
status: 200
- synopsis: Perform a multi-search template query using a POST request.
path: /_msearch/template
method: POST
request:
content_type: application/x-ndjson
payload:
- {index: books}
- {source: '{"query": {"match": {"title": "{{title}}"}}}', params: {title: '1984'}}
- {index: books}
- {source: '{"query": {"match": {"author": "{{author}}"}}}', params: {author: Harper Lee}}
response:
status: 200
- {source: '{"query": {"match": {"title": "{{title}}"}}}', params: {title: Beast}}
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
$schema: ../../../json_schemas/test_story.schema.yaml
$schema: ../../../../json_schemas/test_story.schema.yaml

description: Test endpoints relevant to the lifecycle of an index, including multi-get and multi-search operations.
prologues:
Expand All @@ -22,7 +22,9 @@ epilogues:
chapters:
- synopsis: Perform a `_msearch` request to execute multiple search queries in a single call.
path: /{index}/_msearch
method: GET
method:
- GET
- POST
parameters:
index: books
request:
Expand All @@ -31,20 +33,4 @@ chapters:
- {index: books}
- {query: {match: {title: To Kill a Mockingbird}}}
- {index: books}
- {query: {match: {title: The Cruise}}}
response:
status: 200
- synopsis: Perform a `_msearch` request to execute multiple search queries in a single call (POST).
path: /{index}/_msearch
method: POST
parameters:
index: books
request:
content_type: application/x-ndjson
payload:
- {index: books}
- {query: {match: {title: To Kill a Mockingbird}}}
- {index: books}
- {query: {match: {title: The Cruise}}}
response:
status: 200
- {query: {match: {title: The Cruise}}}
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
$schema: ../../../json_schemas/test_story.schema.yaml
$schema: ../../../../json_schemas/test_story.schema.yaml

description: Test _termvectors and _msearch/template APIs.
description: Test _msearch/template APIs.
prologues:
- path: /_bulk
method: POST
Expand All @@ -25,27 +25,13 @@ chapters:
path: /{index}/_msearch/template
parameters:
index: books
method: GET
method:
- GET
- POST
request:
content_type: application/x-ndjson
payload:
- {index: books}
- {source: '{"query": {"match": {"title": "{{title}}"}}}', params: {title: Mockingbird}}
- {index: books}
- {source: '{"query": {"match": {"title": "{{title}}"}}}', params: {title: Beast}}
response:
status: 200
- synopsis: Perform a multi-search template query using a POST request.
path: /{index}/_msearch/template
parameters:
index: books
method: POST
request:
content_type: application/x-ndjson
payload:
- {index: books}
- {source: '{"query": {"match": {"title": "{{title}}"}}}', params: {title: '1984'}}
- {index: books}
- {source: '{"query": {"match": {"author": "{{author}}"}}}', params: {author: Harper Lee}}
response:
status: 200
- {source: '{"query": {"match": {"title": "{{title}}"}}}', params: {title: Beast}}

0 comments on commit 7effb63

Please sign in to comment.