From 0647954425e89f9982f82f8ae40d8b32402c5837 Mon Sep 17 00:00:00 2001 From: Aditya Thebe Date: Wed, 26 Jun 2024 18:22:46 +0545 Subject: [PATCH] chore: address review comments --- .../docs/reference/1-prometheus.mdx | 30 ++++--- .../docs/reference/topology/components.mdx | 78 +++++++------------ .../docs/reference/topology/index.mdx | 26 +++++-- 3 files changed, 64 insertions(+), 70 deletions(-) diff --git a/canary-checker/docs/reference/1-prometheus.mdx b/canary-checker/docs/reference/1-prometheus.mdx index 2c302213..828754a2 100644 --- a/canary-checker/docs/reference/1-prometheus.mdx +++ b/canary-checker/docs/reference/1-prometheus.mdx @@ -17,38 +17,44 @@ The Prometheus Check connects to the Prometheus host, performs the desired query { field: 'url', description: - 'Prometheus instance, if not specified in installation it is required', + 'Prometheus instance, defaults to `--prometheus` command line argument', required: true }, { field: 'query', description: 'PromQL query to execute', required: true }, { field: 'username', - description: 'PromQL query to execute', + description: 'Username for basic auth', scheme: 'EnvVar' }, { field: 'password', - description: 'PromQL query to execute', + description: 'Password for basic auth', scheme: 'EnvVar' }, { field: 'bearer', - description: 'PromQL query to execute', + description: 'Bearer token to use for authentication', scheme: 'EnvVar' }, - { field: 'oauth', description: 'PromQL query to execute', scheme: '[oAuth](#oauth)' }, + { field: 'oauth', scheme: '[OAuth](#oauth)' } ]} /> ## OAuth - + ## Result Variables diff --git a/mission-control/docs/reference/topology/components.mdx b/mission-control/docs/reference/topology/components.mdx index d79fef61..3ad4f820 100644 --- a/mission-control/docs/reference/topology/components.mdx +++ b/mission-control/docs/reference/topology/components.mdx @@ -10,51 +10,26 @@ Components are the building blocks of a Topology. The component specification pr # Component -| Field | Description | Scheme | Required | -| --------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------ | -------- | -| `checks` | Specify checks based on `inline` and `selector` | [`[]Check`](#check) | | -| `components` | RawMessage is a raw encoded JSON value. It implements Marshaler and Unmarshaler and can be used to delay JSON decoding or pre-compute a JSON encoding. | [`[]Component`](#component) | | -| `configs` | Specify selectors for config items that should be associated with this component. | [`[]Config`](#config-selector) | | -| `forEach` | Only applies when using lookup. When specified, the components and properties specified under ForEach will be templated using the components returned by the lookup. | [`ForEach`](#foreach) | | -| `icon` | Specify icon for component | `string` | | -| `id` | Specify unique ID for component | [`ID`](#id) | | -| `labels` | Labels for the component | `map[string]string` | | -| `lifecycle` | The lifecycle state of the component e.g. production, staging, dev, etc. | `string` | | -| `lookup` | Lookup component definitions from an external source, use the `forEach` property to iterate over the results to further enrich each component. | [`Lookup`](#lookup) | | -| `name` | Set name for component | `string` | | -| `namespace` | Set namespace for component | `string` | | -| `order` | Set integer order value for component | `int` | | -| `owner` | Specify owner of component | `string` | | -| `properties` | Customize component properties as to be visualized on Mission control UI | [`[]Property`](./properties) | | -| `relationships` | Specify relationship of component | [`[]RelationshipSpec`](#relationshipspec) | | -| `selectors` | Specify component for topology based on `fieldSelector` and `labelSelector` | [`[]ResourceSelector`](../resource-selector) | | -| `tooltip` | Set tooltip outlining information pertaining to the component | `string` | | -| `type` | Set type of component e.g. service, API, website, library, database, etc. | `string` | | - -### ID - - - +| Field | Description | Scheme | Required | +| --------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------- | -------- | +| `checks` | Specify checks based on `inline` and `selector` | [`[]Check`](#check) | | +| `components` | RawMessage is a raw encoded JSON value. It implements Marshaler and Unmarshaler and can be used to delay JSON decoding or pre-compute a JSON encoding. | [`[]Component`](#component) | | +| `configs` | Specify selectors for config items that should be associated with this component. | [`[]Config`](#config-selector) | | +| `forEach` | Only applies when using lookup. When specified, the components and properties specified under ForEach will be templated using the components returned by the lookup. | [`ForEach`](#foreach) | | +| `icon` | Specify icon for component | `string` | | +| `id` | Specify unique ID for component | [`ID`](./index.mdx#id-selector) | | +| `labels` | Labels for the component | `map[string]string` | | +| `lifecycle` | The lifecycle state of the component e.g. production, staging, dev, etc. | `string` | | +| `lookup` | Lookup component definitions from an external source, use the `forEach` property to iterate over the results to further enrich each component. | [`Lookup`](#lookup) | | +| `name` | Set name for component | `string` | | +| `namespace` | Set namespace for component | `string` | | +| `order` | Set integer order value for component | `int` | | +| `owner` | Specify owner of component | `string` | | +| `properties` | Customize component properties as to be visualized on Mission control UI | [`[]Property`](./properties) | | +| `relationships` | Specify relationship of component | [`[]RelationshipSpec`](#relationshipspec) | | +| `selectors` | Specify component for topology based on `fieldSelector` and `labelSelector` | [`[]ResourceSelector`](../resource-selector) | | +| `tooltip` | Set tooltip outlining information pertaining to the component | `string` | | +| `type` | Set type of component e.g. service, API, website, library, database, etc. | `string` | | ### RelationshipSpec @@ -65,7 +40,7 @@ oneOf={["expr", "javascript", "template"]} ### ForEach - + ## Config Selector @@ -81,12 +56,11 @@ oneOf={["expr", "javascript", "template"]} ## Check -| Field | Description | Scheme | Required | -| ---------- | -------------------------------- | -------------------------------------------------------------- | -------- | -| `inline` | Define a new health check inline | [`CanarySpec`](/reference/canary-checker) | | -| `selector` | Select an existing health check | [`[]ResourceSelector`](/reference/resource-selector) | | +| Field | Description | Scheme | Required | +| ---------- | -------------------------------- | ---------------------------------------------------- | -------- | +| `inline` | Define a new health check inline | [`CanarySpec`](/reference/canary-checker) | | +| `selector` | Select an existing health check | [`[]ResourceSelector`](/reference/resource-selector) | | ## Lookup - - + diff --git a/mission-control/docs/reference/topology/index.mdx b/mission-control/docs/reference/topology/index.mdx index 15ce9045..ca7375f7 100644 --- a/mission-control/docs/reference/topology/index.mdx +++ b/mission-control/docs/reference/topology/index.mdx @@ -21,12 +21,26 @@ This page defines the specification for Topology. There are few samples in the e ### ID Selector -| Field | Description | Scheme | Required | -| ------------ | ------------------------------------------ | -------- | -------- | -| `expr` | Specify expression for ID | `string` | | -| `javascript` | Specify javascript syntax to generate ID | `string` | | -| `jsonPath` | Specify path to JSON element for use in ID | `string` | | -| `template` | Specify Go template for use in ID | `string` | | + ### Group By