-
Notifications
You must be signed in to change notification settings - Fork 62
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Ruirui Zhang <[email protected]>
- Loading branch information
Showing
2 changed files
with
203 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,135 @@ | ||
openapi: 3.1.0 | ||
info: | ||
title: OpenSearch QueryGroup API | ||
description: OpenSearch QueryGroup API | ||
version: 1.0.0 | ||
paths: | ||
/_query_group: | ||
get: | ||
operationId: query_group.get.0 | ||
x-operation-group: query_group.get | ||
x-version-added: '2.16' | ||
description: Gets the specified QueryGroup or get all if no name is provided. | ||
responses: | ||
'200': | ||
$ref: '#/components/responses/query_group.get@200' | ||
put: | ||
operationId: query_group.put.0 | ||
x-operation-group: query_group.put | ||
x-version-added: '2.16' | ||
description: Creates or updates a specified query group. | ||
requestBody: | ||
$ref: '#/components/requestBodies/query_group.put.0' | ||
responses: | ||
'200': | ||
$ref: '#/components/responses/query_group.put@200' | ||
delete: | ||
operationId: query_group.delete.0 | ||
x-operation-group: query_group.delete | ||
x-version-added: '2.16' | ||
description: Deletes the specified QueryGroups or delete all if no name is provided. | ||
responses: | ||
'200': | ||
$ref: '#/components/responses/query_group.delete@200' | ||
/_query_group/{name}: | ||
get: | ||
operationId: query_group.get.1 | ||
x-operation-group: query_group.get | ||
x-version-added: '2.16' | ||
description: Gets the specified QueryGroup or get all if no name is provided. | ||
parameters: | ||
- $ref: '#/components/parameters/query_group.get::path.name' | ||
responses: | ||
'200': | ||
$ref: '#/components/responses/query_group.get@200' | ||
put: | ||
operationId: query_group.put.1 | ||
x-operation-group: query_group.put | ||
x-version-added: '2.16' | ||
description: Creates or updates a specified query group. | ||
parameters: | ||
- $ref: '#/components/parameters/query_group.put::path.name' | ||
requestBody: | ||
$ref: '#/components/requestBodies/query_group.put.1' | ||
responses: | ||
'200': | ||
$ref: '#/components/responses/query_group.put@200' | ||
delete: | ||
operationId: query_group.delete.1 | ||
x-operation-group: query_group.delete | ||
x-version-added: '2.16' | ||
description: Deletes the specified QueryGroups or delete all if no name is provided. | ||
parameters: | ||
- $ref: '#/components/parameters/query_group.delete::path.name' | ||
responses: | ||
'200': | ||
$ref: '#/components/responses/query_group.delete@200' | ||
components: | ||
requestBodies: | ||
query_group.put.0: | ||
content: | ||
application/json: | ||
schema: | ||
type: object | ||
properties: | ||
$ref: '../schemas/query_group._common.yaml#/components/schemas/QueryGroupCreateStructure' | ||
required: true | ||
query_group.put.1: | ||
content: | ||
application/json: | ||
schema: | ||
type: object | ||
properties: | ||
$ref: '../schemas/query_group._common.yaml#/components/schemas/QueryGroupUpdateStructure' | ||
required: true | ||
responses: | ||
query_group.put@200: | ||
description: '' | ||
content: | ||
application/json: | ||
schema: | ||
$ref: '../schemas/query_group._common.yaml#/components/schemas/QueryGroupResponseStructure' | ||
query_group.delete@200: | ||
description: '' | ||
content: | ||
application/json: | ||
schema: | ||
type: object | ||
properties: | ||
deleted: | ||
type: array | ||
items: | ||
$ref: '../schemas/query_group._common.yaml#/components/schemas/QueryGroupResponseStructure' | ||
query_group.get@200: | ||
description: '' | ||
content: | ||
application/json: | ||
schema: | ||
type: object | ||
properties: | ||
query_groups: | ||
type: array | ||
items: | ||
$ref: '../schemas/query_group._common.yaml#/components/schemas/QueryGroupResponseStructure' | ||
parameters: | ||
query_group.put::path.name: | ||
name: name | ||
in: path | ||
description: QueryGroup name. | ||
schema: | ||
type: string | ||
required: true | ||
query_group.delete::path.name: | ||
name: name | ||
in: path | ||
description: QueryGroup name. | ||
schema: | ||
type: string | ||
required: true | ||
query_group.get::path.name: | ||
name: name | ||
in: path | ||
description: QueryGroup name. | ||
schema: | ||
type: string | ||
required: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
openapi: 3.1.0 | ||
info: | ||
title: Schemas of query_group._common category | ||
description: Schemas of query_group._common category | ||
version: 1.0.0 | ||
paths: {} | ||
components: | ||
schemas: | ||
QueryGroupResponseStructure: | ||
type: object | ||
properties: | ||
name: | ||
type: string | ||
resiliency_mode: | ||
type: string | ||
enum: [ "soft", "enforced", "monitor" ] | ||
jvm: | ||
type: number | ||
format: double | ||
cpu: | ||
type: number | ||
format: double | ||
updatedAt: | ||
type: integer | ||
format: int64 | ||
anyOf: | ||
- required: | ||
- jvm | ||
- required: | ||
- cpu | ||
required: | ||
- name | ||
- resiliency_mode | ||
- updatedAt | ||
QueryGroupCreateStructure: | ||
type: object | ||
properties: | ||
name: | ||
type: string | ||
resiliency_mode: | ||
type: string | ||
enum: [ "soft", "enforced", "monitor" ] | ||
jvm: | ||
type: number | ||
format: double | ||
cpu: | ||
type: number | ||
format: double | ||
anyOf: | ||
- required: | ||
- jvm | ||
- required: | ||
- cpu | ||
required: | ||
- name | ||
- resiliency_mode | ||
QueryGroupUpdateStructure: | ||
type: object | ||
properties: | ||
resiliency_mode: | ||
type: string | ||
enum: [ "soft", "enforced", "monitor" ] | ||
jvm: | ||
type: number | ||
format: double | ||
cpu: | ||
type: number | ||
format: double |