Skip to content

Fix Missing Links in Mission Control Documentation #386

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions canary-checker/docs/concepts/metrics-exporter.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
---
title: Metrics Exporter
slug: /concepts/metrics-exporter
---

# Metrics Exporter

Canary Checker works well with Prometheus and exports metrics for every check, the standard metrics included are:

| Metric | Type | Description |
| ---------------------------------------------- | --------- | ------------------------------------------- |
| canary_check | Gauge | Set to 0 when passing and 1 when failing |
| canary_check_success_count | Counter | |
| canary_check_failed_count | Counter | |
| canary_check_info | Info | |
| canary_check_duration | Histogram | Histogram of canary durations |

For more information about metrics, including custom metrics and Grafana integration, please visit the [metrics page](/concepts/metrics).
47 changes: 47 additions & 0 deletions canary-checker/docs/concepts/metrics/custom-metrics.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
---
title: Custom Metrics
slug: /concepts/metrics/custom-metrics
---

# Custom Metrics

Canary checker can export custom metrics from any check type, replacing and/or consolidating multiple standalone Prometheus Exporters into a single exporter.

In the example below, exchange rates against USD are exported by first calling an HTTP api and then using the values from the JSON response to create the metrics:

```yaml title="exchange-rates-exporter.yaml"
apiVersion: canaries.flanksource.com/v1
kind: Canary
metadata:
name: exchange-rates
spec:
interval: 30
http:
- name: exchange-rates-api
url: https://api.exchangerate-api.com/v4/latest/USD
responseTime: 300
metrics:
- name: exchange_rate_api
type: gauge
value: duration
- name: exchange_rate
type: gauge
value: "1.0"
labels:
- name: from
value: USD
- name: to
valueExpr: key
values: json.rates.*
```

Which would output:

```shell
exchange_rate{from=USD, to=GBP} 0.819
exchange_rate{from=USD, to=EUR} 0.949
exchange_rate{from=USD, to=ILS} 3.849
exchange_rate_api 260.000
```

For more information about custom metrics, please visit the [main metrics page](/concepts/metrics#custom-metrics).
16 changes: 16 additions & 0 deletions canary-checker/docs/concepts/metrics/grafana.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
---
title: Grafana Integration
slug: /concepts/metrics/grafana
---

# Grafana

Default grafana dashboards are available. After you deploy Grafana, these dashboards can be installed with

```
--set grafanaDashboards=true --set serviceMonitor=true
```

![](/img/grafana-dashboard.png)

For more information about metrics and Grafana, please visit the [main metrics page](/concepts/metrics#grafana).
8 changes: 8 additions & 0 deletions canary-checker/docs/docs/getting-started/installation.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
title: Getting Started with Installation
slug: /docs/getting-started/installation
---

import {Redirect} from '@docusaurus/router';

<Redirect to="/getting-started" />
35 changes: 18 additions & 17 deletions canary-checker/docusaurus.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -91,22 +91,23 @@ export default async function createConfigAsync() {
['@docusaurus/plugin-client-redirects',
{
redirects: [
{
to: '/getting-started',
from: '/docs/getting-started/installation',
},
{
to: '/concepts/metrics#grafana',
from: '/concepts/metrics/grafana',
},
{
to: '/concepts/metrics',
from: '/concepts/metrics/custom-metrics',
},
{
to: '/concepts/metrics',
from: '/concepts/metrics-exporter',
}
// These redirects are no longer needed as we've created the source files
// {
// to: '/getting-started',
// from: '/docs/getting-started/installation',
// },
// {
// to: '/concepts/metrics#grafana',
// from: '/concepts/metrics/grafana',
// },
// {
// to: '/concepts/metrics',
// from: '/concepts/metrics/custom-metrics',
// },
// {
// to: '/concepts/metrics',
// from: '/concepts/metrics-exporter',
// }
],
}

Expand Down Expand Up @@ -178,4 +179,4 @@ export default async function createConfigAsync() {
},
}),
};
}
}
8 changes: 8 additions & 0 deletions mission-control/docs/canary-checker.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
title: Canary Checker
slug: /canary-checker
---

import {Redirect} from '@docusaurus/router';

<Redirect to="/guide/canary-checker" />
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ When building a topology, templating enables you to transform data from the cata
**Templating is:**
> Simply a way to represent data in different forms.

Templating comes in handy when you want the results of your operation displayed in your desired configuration and order. [Canary-checker](/guide/canary-checker/overview) and [Config DB](/guide/config-db/getting-started) supports this feature for rendering results. They can be specified in `display`, `test`, `transform` fields for the `Canary` object, `id`, `test`, `transform`, `display` for `Topology` object. The template can be configured In the next section, you'll see the different supported templates.
Templating comes in handy when you want the results of your operation displayed in your desired configuration and order. [Canary-checker](/guide/canary-checker) and [Config DB](/guide/config-db/getting-started) supports this feature for rendering results. They can be specified in `display`, `test`, `transform` fields for the `Canary` object, `id`, `test`, `transform`, `display` for `Topology` object. The template can be configured In the next section, you'll see the different supported templates.

## Canary Template Types

Expand Down
8 changes: 8 additions & 0 deletions mission-control/docs/notifications.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
title: Notifications
slug: /notifications
---

import {Redirect} from '@docusaurus/router';

<Redirect to="/guide/notifications" />
8 changes: 8 additions & 0 deletions mission-control/docs/playbooks.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
title: Playbooks
slug: /playbooks
---

import {Redirect} from '@docusaurus/router';

<Redirect to="/guide/playbooks" />
8 changes: 8 additions & 0 deletions mission-control/docs/topology.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
title: Topology
slug: /topology
---

import {Redirect} from '@docusaurus/router';

<Redirect to="/guide/topology" />
35 changes: 18 additions & 17 deletions mission-control/docusaurus.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -67,22 +67,23 @@ export default async function createConfigAsync() {
// from: '/guide/canary-checker/reference/s3-bucket',
// },

{
to: '/guide/canary-checker',
from: '/canary-checker',
},
{
to: '/guide/playbooks',
from: '/playbooks',
},
{
to: '/guide/notifications/',
from: '/notifications',
},
{
to: '/guide/topology',
from: '/topology',
},
// These redirects are no longer needed as we've created the source files
// {
// to: '/guide/canary-checker',
// from: '/canary-checker',
// },
// {
// to: '/guide/playbooks',
// from: '/playbooks',
// },
// {
// to: '/guide/notifications/',
// from: '/notifications',
// },
// {
// to: '/guide/topology',
// from: '/topology',
// },

],

Expand Down Expand Up @@ -336,4 +337,4 @@ export default async function createConfigAsync() {
},
}),
}
}
}
Loading