From ccb64d1380df1e7562ec88438ce6273a192ffc16 Mon Sep 17 00:00:00 2001 From: ShashiSubramanya Date: Fri, 31 Jul 2026 12:35:50 +0530 Subject: [PATCH 1/2] record_size updates --- modules/ROOT/pages/deploy-with-tml-apis.adoc | 14 ++++++++++---- modules/ROOT/pages/rest-api-v2-groups-search.adoc | 10 ++++++---- .../ROOT/pages/rest-api-v2-metadata-search.adoc | 6 ++++-- modules/ROOT/pages/rest-api-v2-search.adoc | 7 ++++++- modules/ROOT/pages/rest-api-v2-users-search.adoc | 11 +++++++---- 5 files changed, 33 insertions(+), 15 deletions(-) diff --git a/modules/ROOT/pages/deploy-with-tml-apis.adoc b/modules/ROOT/pages/deploy-with-tml-apis.adoc index e09eaf7d8..ee27c497f 100644 --- a/modules/ROOT/pages/deploy-with-tml-apis.adoc +++ b/modules/ROOT/pages/deploy-with-tml-apis.adoc @@ -132,7 +132,7 @@ You can add multiple tags, if you'd like to add tags indicating versioning along The `/metadata/search` REST API endpoint has parameters to filter on `tag_identifiers` and `created_by_user_identifiers`. The response from `/metadata/search` can be processed further to reduce down to the desired list of object IDs to pass to the `/metadata/tml/export` endpoint. -[,json] +[source,json] ---- { "metadata": [ @@ -142,14 +142,20 @@ The `/metadata/search` REST API endpoint has parameters to filter on `tag_identi ], "tag_identifiers": ["release"], "sort_options": { - "field_name": order_field, + "field_name": "NAME", "order": "DESC" }, - "record_size" : -1, - "record_offset": 0 + "record_size": 1000, + "record_offset": 0 } ---- + +[CAUTION] +==== +Do not set `record_size` to `-1`. On ThoughtSpot instances with a large number of objects or users, this can lead to slow responses, excessive logging, and out-of-memory failures. Specify an explicit `record_size` and iterate through pages programmatically. +==== + The `author` property of an object in the REST API is the value that the `created_by_user_identifiers` parameter in the `/metadata/search` endpoint filters on. `author` can be reassigned from the original creator via the link:https://developers.thoughtspot.com/docs/restV2-playground?apiResourceId=http%2Fapi-endpoints%2Fsecurity%2Fassign-change-author[/security/metadata/assign, window=_blank] endpoint. [#linkExportSource] diff --git a/modules/ROOT/pages/rest-api-v2-groups-search.adoc b/modules/ROOT/pages/rest-api-v2-groups-search.adoc index 779b503cd..470cdc3dd 100644 --- a/modules/ROOT/pages/rest-api-v2-groups-search.adoc +++ b/modules/ROOT/pages/rest-api-v2-groups-search.adoc @@ -14,7 +14,7 @@ The overall structure of `groups/search` request is link:https://developers.thou Note that many parameters in the request are *optional*, and leaving the parameter name out entirely has a different effect from including the parameter and specific values. -Throughout this article, requests and responses will be shown as JSON, without any of the code to send the requests. The v2.0 Playground generates requests that always include the default values for any parameters that have them, but this article excludes them. Assume every request you see has the following parameters in addition to what is shown: +This article shows requests and responses as JSON. The v2.0 Playground generates requests that always include the default values for any parameters that have them, but this article excludes them. Assume every request you see has the following parameters in addition to what is shown: [source,JSON] ---- @@ -24,8 +24,10 @@ Throughout this article, requests and responses will be shown as JSON, without a } ---- -For precise results, you can set `record_size` to `-1` and `record_offset` to `0`. - +[CAUTION] +==== +Do not set `record_size` to `-1`. On ThoughtSpot instances with a large number of objects or users, this can lead to slow responses, excessive logging, and out-of-memory failures. Specify an explicit `record_size` and iterate through pages programmatically. +==== == Response format The response from any call to `groups/search` will resemble the following: @@ -86,7 +88,7 @@ For example, to see *all groups*, you can simply send the `record_offset` and `r ---- { "record_offset": 0, - "record_size": 100000 + "record_size": 1000 } ---- diff --git a/modules/ROOT/pages/rest-api-v2-metadata-search.adoc b/modules/ROOT/pages/rest-api-v2-metadata-search.adoc index 718d098b8..8d9db7408 100644 --- a/modules/ROOT/pages/rest-api-v2-metadata-search.adoc +++ b/modules/ROOT/pages/rest-api-v2-metadata-search.adoc @@ -3803,8 +3803,10 @@ By default, the following pagination settings are applied to the API response re } ---- -If you are not using filtering options such as `tag_identifiers`, `type`, `created_by_user_identifiers`, `modified_by_user_identifiers`, `owned_by_user_identifiers`, `exclude_objects`, `include_auto_created_objects`, or `favorite_object_options`, set `record_size` to `-1` and `record_offset` to `0` for precise results. - +[CAUTION] +==== +Do not set `record_size` to `-1`. On ThoughtSpot instances with a large number of objects or users, this can lead to slow responses, excessive logging, and out-of-memory failures. Specify an explicit `record_size` and iterate through pages programmatically. +==== diff --git a/modules/ROOT/pages/rest-api-v2-search.adoc b/modules/ROOT/pages/rest-api-v2-search.adoc index 208d16cfd..d29a5c231 100644 --- a/modules/ROOT/pages/rest-api-v2-search.adoc +++ b/modules/ROOT/pages/rest-api-v2-search.adoc @@ -12,7 +12,7 @@ Some capabilities that have separate endpoints in the V1 REST API are done using Note that many parameters in the requests are *optional*, and leaving the parameter name out entirely has a different effect from including the parameter and specific values. -Throughout this article, requests and responses will be shown as JSON, without any of the code to send the requests. The V2.0 Playground generates requests that always include the default values for any parameters that have them, but this article excludes them. +This page shows the requests and responses as JSON, without any of the code to send the requests. The V2.0 Playground generates requests that always include the default values for any parameters that have them, but this article excludes them. Assume every request you see has the following parameters in addition to what is shown: @@ -24,6 +24,11 @@ Assume every request you see has the following parameters in addition to what is } ---- +[CAUTION] +==== +Do not set `record_size` to `-1`. On ThoughtSpot instances with a large number of objects or users, this can lead to slow responses, excessive logging, and out-of-memory failures. Specify an explicit `record_size` and iterate through pages programmatically. +==== + == Search metadata The `/metadata/search` endpoint in the V2 REST API replaces a large set of distinct endpoints in REST API V1. diff --git a/modules/ROOT/pages/rest-api-v2-users-search.adoc b/modules/ROOT/pages/rest-api-v2-users-search.adoc index fc2e4f099..8debfde0b 100644 --- a/modules/ROOT/pages/rest-api-v2-users-search.adoc +++ b/modules/ROOT/pages/rest-api-v2-users-search.adoc @@ -14,7 +14,7 @@ The overall structure of `users/search` request is link:https://developers.thoug Note that many parameters in the request are *optional*, and leaving the parameter name out entirely has a different effect from including the parameter and specific values. -Throughout this article, requests and responses will be shown as JSON, without any of the code to send the requests. The V2.0 Playground generates requests that always include the default values for any parameters that have them, but this article excludes them. Assume every request you see has the following parameters in addition to what is shown: +This article shows requests and responses as JSON. The V2.0 Playground generates requests that always include the default values for any parameters that have them, but this article excludes them. Assume every request you see has the following parameters in addition to what is shown: [source,JSON] ---- @@ -24,7 +24,10 @@ Throughout this article, requests and responses will be shown as JSON, without a } ---- -For precise results, you can set `record_size` to `-1` and `record_offset` to `0`. +[CAUTION] +==== +Do not set `record_size` to `-1`. On ThoughtSpot instances with a large number of objects or users, this can lead to slow responses, excessive logging, and out-of-memory failures. Specify an explicit `record_size` and iterate through pages programmatically. +==== == Response format The response from any call to `users/search` will resemble the following: @@ -96,13 +99,13 @@ The response from any call to `users/search` will resemble the following: The `/users/search` API performs listing functions when you do not send specific object IDs as part of your request. Note you must send some request in the body of the POST, even if this is only `{ }`. -For example, to see *all users*, you can simply send the `record_offset` and `record_size` parameters: +For example, to see *all users*, set the `record_offset` and `record_size` parameters. [source,JSON] ---- { "record_offset": 0, - "record_size": 100000 + "record_size": 1000 } ---- From da72beca4f06d27f0ce2a399f46e772563609993 Mon Sep 17 00:00:00 2001 From: ShashiSubramanya Date: Fri, 31 Jul 2026 14:56:17 +0530 Subject: [PATCH 2/2] caution/warning block style fixes --- src/assets/styles/admonition.scss | 6 ++--- src/assets/styles/index.scss | 37 +++++++++++++++++++++++-------- src/assets/styles/variables.scss | 18 +++++++++++++++ 3 files changed, 49 insertions(+), 12 deletions(-) diff --git a/src/assets/styles/admonition.scss b/src/assets/styles/admonition.scss index e7dd3e6f4..f69f23026 100644 --- a/src/assets/styles/admonition.scss +++ b/src/assets/styles/admonition.scss @@ -57,7 +57,7 @@ } &.caution .icon { - color: $caution-color; + color: var(--var-caution-color); } &.important .icon { @@ -69,11 +69,11 @@ } &.tip .icon { - color: $tip-color; + color: var(--var-tip-color); } &.warning .icon { - color: $warning-color; + color: var(--var-warning-color); } & > table { diff --git a/src/assets/styles/index.scss b/src/assets/styles/index.scss index baf0ec97c..18d3cd746 100644 --- a/src/assets/styles/index.scss +++ b/src/assets/styles/index.scss @@ -680,29 +680,48 @@ button { padding-bottom: 10px; } } +.admonitionblock.caution { + border-left: 4px solid var(--var-caution-color); + td.content { + border: 1px solid var(--caution-border-color); + box-shadow: 0 1px 1px var(--caution-border-color); + border-radius: 5px !important; + background: var(--caution-block-color); + } + td.icon { + left: 20px !important; + top: 10px !important; + padding-bottom: 10px; + } +} + .admonitionblock.warning { - border-left: 5px solid $warning-color; + border-left: 4px solid var(--var-warning-color); td.content { - border: none !important; - border-radius: 0 !important; - box-shadow: none !important; + border: 1px solid var(--warning-border-color); + box-shadow: 0 1px 1px var(--warning-border-color); + border-radius: 5px !important; + background: var(--warning-block-color); } td.icon { left: 20px !important; - top: 5px !important; + top: 10px !important; + padding-bottom: 10px; } } .admonitionblock.tip { - border-left: 5px solid $tip-color; + border-left: 4px solid var(--var-tip-color); td.content { - border: 0 !important; - border-radius: 0.5 !important; - box-shadow: none !important; + border: 1px solid var(--tip-border-color); + box-shadow: 0 1px 1px var(--tip-border-color); + border-radius: 5px !important; + background: var(--tip-block-color); } td.icon { left: 20px !important; top: 10px !important; + padding-bottom: 10px; } } diff --git a/src/assets/styles/variables.scss b/src/assets/styles/variables.scss index cb6346fc1..cc10d04ac 100644 --- a/src/assets/styles/variables.scss +++ b/src/assets/styles/variables.scss @@ -249,6 +249,15 @@ $tag-color-light: $lightgrey; --var-important-color: #e22b3d; --important-border-color: #cccdcd; --important-block-color: #f1f4f8; + --var-caution-color: #ff8142; + --caution-block-color: #fff1e8; + --caution-border-color: #f7b98e; + --var-tip-color: #2f8f39; + --tip-block-color: #eefbf0; + --tip-border-color: #94d69a; + --var-warning-color: #ff8142; + --warning-block-color: #fff1e8; + --warning-border-color: #f7b98e; --var-docmap-nested-color: #6b7280; --box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06); --box-shadow-hover: 0 4px 6px -1px rgba(0, 0, 0, 0.1), @@ -323,6 +332,15 @@ $tag-color-light: $lightgrey; --var-important-color: #e22b3d; --important-border-color: #30363d; --important-block-color: #1e2430; + --var-caution-color: #ff8142; + --caution-block-color: #1e2430; + --caution-border-color: #ff8142; + --var-tip-color: #3fb950; + --tip-block-color: #1e2430; + --tip-border-color: #3fb950; + --var-warning-color: #ff8142; + --warning-block-color: #1e2430; + --warning-border-color: #ff8142; --var-docmap-nested-color: #8b949e; --sidebar-connector-color: #30363d; --copy-btn-bg: #21262d;