From a14a618f1d9e27525114d1cbebe5aa25bedcc593 Mon Sep 17 00:00:00 2001 From: Tokesh Date: Wed, 24 Jul 2024 10:43:51 +0500 Subject: [PATCH] fix structure of sql stats API Signed-off-by: Tokesh --- spec/namespaces/sql.yaml | 8 ++++---- spec/schemas/sql._common.yaml | 2 ++ tests/sql/stats.yaml | 3 ++- 3 files changed, 8 insertions(+), 5 deletions(-) diff --git a/spec/namespaces/sql.yaml b/spec/namespaces/sql.yaml index c9e8fe36d..fc3cf4a64 100644 --- a/spec/namespaces/sql.yaml +++ b/spec/namespaces/sql.yaml @@ -204,13 +204,13 @@ components: required: true sql.get_stats@200: content: - application/json: + text/plain: schema: - $ref: '../schemas/sql._common.yaml#/components/schemas/SqlStatsResponse' + type: string required: true sql.post_stats@200: content: - application/json: + text/plain: schema: - $ref: '../schemas/sql._common.yaml#/components/schemas/SqlStatsResponse' + type: string required: true \ No newline at end of file diff --git a/spec/schemas/sql._common.yaml b/spec/schemas/sql._common.yaml index 75746eac2..785a06468 100644 --- a/spec/schemas/sql._common.yaml +++ b/spec/schemas/sql._common.yaml @@ -26,6 +26,8 @@ components: type: array items: type: array + cursor: + type: string total: type: integer size: diff --git a/tests/sql/stats.yaml b/tests/sql/stats.yaml index d56838b9c..cbb8d7db1 100644 --- a/tests/sql/stats.yaml +++ b/tests/sql/stats.yaml @@ -7,4 +7,5 @@ chapters: path: /_plugins/_sql/stats method: POST response: - status: 200 \ No newline at end of file + status: 200 + content_type: text/plain \ No newline at end of file