From 6bd81e61ba82a2da674d2dc43aec68835e3387ff Mon Sep 17 00:00:00 2001 From: SamyOubouaziz Date: Mon, 10 Feb 2025 15:01:10 +0100 Subject: [PATCH 1/7] docs(srv): add how to create alerts for srv ressources MTA-5503 --- menu/navigation.json | 4 ++ .../how-to/configure-alerts-function.mdx | 59 +++++++++++++++++++ 2 files changed, 63 insertions(+) create mode 100644 pages/serverless-functions/how-to/configure-alerts-function.mdx diff --git a/menu/navigation.json b/menu/navigation.json index 90b5717fd6..6e7b4e7223 100644 --- a/menu/navigation.json +++ b/menu/navigation.json @@ -3932,6 +3932,10 @@ "label": "Monitor function logs and metrics", "slug": "monitor-function" }, + { + "label": "Configure alerts for a function", + "slug": "configure-alerts-function" + }, { "label": "Delete a function", "slug": "delete-a-function" diff --git a/pages/serverless-functions/how-to/configure-alerts-function.mdx b/pages/serverless-functions/how-to/configure-alerts-function.mdx new file mode 100644 index 0000000000..578675a003 --- /dev/null +++ b/pages/serverless-functions/how-to/configure-alerts-function.mdx @@ -0,0 +1,59 @@ +--- +meta: + title: How to add alerts to a function + description: Learn how to add monitoring alerts to Serverless Functions with Scaleway. +content: + h1: How to add alerts to a function + paragraph: Learn how to add monitoring alerts to Serverless Functions with Scaleway. +tags: functions alerts grafana threshold monitoring cockpit +dates: + validation: 2025-02-10 + posted: 2025-02-10 +categories: + - serverless +--- + +This page shows you how to configure alerts for Scaleway Serverless Functions using Scaleway Cockpit and Grafana. + + + + - A Scaleway account logged into the [console](https://console.scaleway.com) + - [Owner](/iam/concepts/#owner) status or [IAM permissions](/iam/concepts/#permission) allowing you to perform actions in the intended Organization + - Scaleway resources you can monitor + - [Created Grafana credentials](/cockpit/how-to/retrieve-grafana-credentials/) with the **Editor** role + - [Enabled](/cockpit/how-to/enable-alert-manager/) the alert manager, and [activated preconfigured alerts](/cockpit/how-to/activate-managed-alerts/) + - [Created](/cockpit/how-to/add-contact-points/) at least one contact point + - Selected the **Scaleway Alerting** alert manager in Grafana + +1. [Log in to Grafana](/cockpit/how-to/access-grafana-and-managed-dashboards/) using your credentials. +2. Click the **Toggle menu** then click **Alerting**. +3. Click **Alert rules** and **+ New alert rule**. +4. Scroll down to the **Define query and alert condition** section and click **Switch to data source-managed alert rule**. + + This allows you to configure alert rules managed by the data source of your choice, instead of using Grafana's managed alert rules. + + +5. Type in a name for your alert. +6. Select the data source you want to configure alerts for. For the sake of this documentation, we are choosing the **Scaleway Metrics** data source. +7. In the Metrics browser drop-down, select the metric you want to configure an alert for. Refer to the table below for details on each alert for Serverless Functions. + + | Rule name | Pending period | Summary | Query and alert condition | Description | + |----------------------------|----------------|---------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------| + | AnyFunctionError | 10s | Function `{{ $labels.resource_name }}` is in error. | `serverless_function_status{status="error"} == 1 ` | Function `{{ $labels.resource_name }}` with id `$labels.resource_id }}` is in error. Check the console to find out the error message. | + | FunctionError | | Function `{{ $labels.resource_name }}` is in error. | `serverless_function_status{status="error",resource_id="your-function-id-here"} == 1 ` | Function `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is in error. Check the console to find out the error message. | + | AnyFunctionHighCPUUsage | 10m | High CPU usage for function `{{ $labels.resource_name }}`. | `serverless_function_cpu_usage_ratio > 90 ` | Function `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available CPU since 10m. | + | FunctionHighCPUUsage | | High CPU usage for function `{{ $labels.resource_name }}`. | `serverless_function_cpu_usage_ratio{resource_id="your-function-id-here"} > 90 ` | Function `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available CPU since 10m. | + | AnyFunctionHighMemoryUsage | 10m | High memory usage for function `{{ $labels.resource_name }}` | `(serverless_function_memory_usage_bytes / serverless_function_memory_limit_bytes) * 100 > 90 ` | Function `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available RAM since 10m. | + | FunctionHighMemoryUsage | | High memory usage for function `{{ $labels.resource_name }}` | `(serverless_function_memory_usage_bytes{resource_id="your-container-id-here"} / serverless_function_memory_limit_bytes{resource_id="your-container-id-here"}) * 100 > 90` | Function `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available RAM since 10m. | + +8. Select labels that apply to the metric you have selected in the previous step, to target your desired resources and fine-tune your alert. +9. Select one or more values for your labels. +10. Click **Use query** to generate your alert based on the conditions you have defined. +11. Select a folder to store your rule, or create a new one. Folders allow you to easily manage your different rules. +12. Select an evaluation group to add your rule to. Rules within the same group are evaluated sequentially over the same time interval. +13. In the **Set alert evaluation behavior** field, configure the amount of time during which the alert can be in breach of the condition(s) you have defined until it triggers. + + For example, if you wish to be alerted after your alert has been in breach of the condition for 2 minutes without interruption, type `2` and select `minutes` in the drop-down. + +14. Optionally, add a summary and a description. +15. Click **Save rule** at the top right corner of your screen to save your alert. Once your alert meets the requirements you have configured, you will receive an email to inform you that your alert has triggered. From d6500b19fa8ae1aa70873ae9910dea9fb7140b7f Mon Sep 17 00:00:00 2001 From: SamyOubouaziz Date: Thu, 13 Feb 2025 12:02:07 +0100 Subject: [PATCH 2/7] docs(srv): update --- .../how-to/configure-alerts-containers.mdx | 158 ++++++++++++++++++ .../how-to/configure-alerts-function.mdx | 115 ++++++++++++- 2 files changed, 265 insertions(+), 8 deletions(-) create mode 100644 pages/serverless-containers/how-to/configure-alerts-containers.mdx diff --git a/pages/serverless-containers/how-to/configure-alerts-containers.mdx b/pages/serverless-containers/how-to/configure-alerts-containers.mdx new file mode 100644 index 0000000000..66b63a5a7e --- /dev/null +++ b/pages/serverless-containers/how-to/configure-alerts-containers.mdx @@ -0,0 +1,158 @@ +--- +meta: + title: How to add alerts to a container + description: Learn how to add monitoring alerts to Serverless Containers with Scaleway. +content: + h1: How to add alerts to a container + paragraph: Learn how to add monitoring alerts to Serverless Containers with Scaleway. +tags: containers alerts grafana threshold monitoring cockpit +dates: + validation: 2025-02-10 + posted: 2025-02-10 +categories: + - serverless +--- + +This page shows you how to configure alerts for Scaleway Serverless Containers using Scaleway Cockpit and Grafana. + + + + - A Scaleway account logged into the [console](https://console.scaleway.com) + - [Owner](/iam/concepts/#owner) status or [IAM permissions](/iam/concepts/#permission) allowing you to perform actions in the intended Organization + - Scaleway resources you can monitor + - [Created Grafana credentials](/cockpit/how-to/retrieve-grafana-credentials/) with the **Editor** role + - [Enabled](/cockpit/how-to/enable-alert-manager/) the alert manager, and [activated preconfigured alerts](/cockpit/how-to/activate-managed-alerts/) + - [Created](/cockpit/how-to/add-contact-points/) at least one contact point + - Selected the **Scaleway Alerting** alert manager in Grafana + +1. [Log in to Grafana](/cockpit/how-to/access-grafana-and-managed-dashboards/) using your credentials. +2. Click the **Toggle menu** then click **Alerting**. +3. Click **Alert rules** and **+ New alert rule**. +4. Scroll down to the **Define query and alert condition** section and click **Switch to data source-managed alert rule**. + + This allows you to configure alert rules managed by the data source of your choice, instead of using Grafana's managed alert rules. + + +5. Type in a name for your alert. +6. Select the data source you want to configure alerts for. For the sake of this documentation, we are choosing the **Scaleway Metrics** data source. +7. In the Metrics browser drop-down, select the metric you want to configure an alert for. Refer to the table below for details on each alert for Serverless Containers. + + **AnyContainerError** + + Pending period + + : 10s + + Summary + + : Container `{{ $labels.resource_name }}` is in error. + + Query and alert condition + + : `serverless_container_status{status="error"} == 1` + + Description + + : Container `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is in error. Check the console to find out the error message. + + **ContainerError** + + Pending period + + : 10s + + Summary + + : Container `{{ $labels.resource_name }}` is in error. + + Query and alert condition + + : `serverless_container_status{status="error",resource_id="your-container-id-here"} == 1` + + Description + + : Container `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is in error. Check the console to find out the error message. + + **AnyContainerHighCPUUsage** + + Pending period + + : 10m + + Summary + + : High CPU usage for container `{{ $labels.resource_name }}`. + + Query and alert condition + + : `serverless_container_cpu_usage_ratio > 90` + + Description + + : Container `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available CPU since 10m. + + **ContainerHighCPUUsage** + + Pending period + + : 10m + + Summary + + : High CPU usage for container `{{ $labels.resource_name }}`. + + Query and alert condition + + : `serverless_container_cpu_usage_ratio{resource_id="your-container-id-here"} > 90` + + Description + + : Container `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available CPU since 10m. + + **AnyContainerHighMemoryUsage** + + Pending period + + : 10m + + Summary + + : High memory usage for container `{{ $labels.resource_name }}`. + + Query and alert condition + + : `(serverless_container_memory_usage_bytes / serverless_container_memory_limit_bytes) * 100 > 90` + + Description + + : Container `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available RAM since 10m. + + **ContainerHighMemoryUsage** + + Pending period + + : 10m + + Summary + + : High memory usage for container `{{ $labels.resource_name }}`. + + Query and alert condition + + : `(serverless_container_memory_usage_bytes{resource_id="your-container-id-here"} / serverless_container_memory_limit_bytes{resource_id="your-container-id-here"}) * 100 > 90` + + Description + + : Container `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available RAM since 10m. + +8. Select labels that apply to the metric you have selected in the previous step, to target your desired resources and fine-tune your alert. +9. Select one or more values for your labels. +10. Click **Use query** to generate your alert based on the conditions you have defined. +11. Select a folder to store your rule, or create a new one. Folders allow you to easily manage your different rules. +12. Select an evaluation group to add your rule to. Rules within the same group are evaluated sequentially over the same time interval. +13. In the **Set alert evaluation behavior** field, configure the amount of time during which the alert can be in breach of the condition(s) you have defined until it triggers. + + For example, if you wish to be alerted after your alert has been in breach of the condition for 2 minutes without interruption, type `2` and select `minutes` in the drop-down. + +14. Optionally, add a summary and a description. +15. Click **Save rule** at the top right corner of your screen to save your alert. Once your alert meets the requirements you have configured, you will receive an email to inform you that your alert has triggered. diff --git a/pages/serverless-functions/how-to/configure-alerts-function.mdx b/pages/serverless-functions/how-to/configure-alerts-function.mdx index 578675a003..957071ee69 100644 --- a/pages/serverless-functions/how-to/configure-alerts-function.mdx +++ b/pages/serverless-functions/how-to/configure-alerts-function.mdx @@ -36,15 +36,114 @@ This page shows you how to configure alerts for Scaleway Serverless Functions us 5. Type in a name for your alert. 6. Select the data source you want to configure alerts for. For the sake of this documentation, we are choosing the **Scaleway Metrics** data source. 7. In the Metrics browser drop-down, select the metric you want to configure an alert for. Refer to the table below for details on each alert for Serverless Functions. + + **AnyFunctionError** - | Rule name | Pending period | Summary | Query and alert condition | Description | - |----------------------------|----------------|---------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------| - | AnyFunctionError | 10s | Function `{{ $labels.resource_name }}` is in error. | `serverless_function_status{status="error"} == 1 ` | Function `{{ $labels.resource_name }}` with id `$labels.resource_id }}` is in error. Check the console to find out the error message. | - | FunctionError | | Function `{{ $labels.resource_name }}` is in error. | `serverless_function_status{status="error",resource_id="your-function-id-here"} == 1 ` | Function `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is in error. Check the console to find out the error message. | - | AnyFunctionHighCPUUsage | 10m | High CPU usage for function `{{ $labels.resource_name }}`. | `serverless_function_cpu_usage_ratio > 90 ` | Function `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available CPU since 10m. | - | FunctionHighCPUUsage | | High CPU usage for function `{{ $labels.resource_name }}`. | `serverless_function_cpu_usage_ratio{resource_id="your-function-id-here"} > 90 ` | Function `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available CPU since 10m. | - | AnyFunctionHighMemoryUsage | 10m | High memory usage for function `{{ $labels.resource_name }}` | `(serverless_function_memory_usage_bytes / serverless_function_memory_limit_bytes) * 100 > 90 ` | Function `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available RAM since 10m. | - | FunctionHighMemoryUsage | | High memory usage for function `{{ $labels.resource_name }}` | `(serverless_function_memory_usage_bytes{resource_id="your-container-id-here"} / serverless_function_memory_limit_bytes{resource_id="your-container-id-here"}) * 100 > 90` | Function `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available RAM since 10m. | + Pending period + + : 10s + + Summary + + : Function `{{ $labels.resource_name }}` is in error. + + Query and alert condition + + : `serverless_function_status{status="error"} == 1` + + Description + + : Function `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is in error. Check the console to find out the error message. + + **FunctionError** + + Pending period + + : 10s + + Summary + + : Function `{{ $labels.resource_name }}` is in error. + + Query and alert condition + + : `serverless_function_status{status="error",resource_id="your-function-id-here"} == 1` + + Description + + : Function `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is in error. Check the console to find out the error message. + + **AnyFunctionHighCPUUsage** + + Pending period + + : 10m + + Summary + + : High CPU usage for function `{{ $labels.resource_name }}`. + + Query and alert condition + + : `serverless_function_cpu_usage_ratio > 90` + + Description + + : Function `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available CPU since 10m. + + **FunctionHighCPUUsage** + + Pending period + + : 10m + + Summary + + : High CPU usage for function `{{ $labels.resource_name }}`. + + Query and alert condition + + : `serverless_function_cpu_usage_ratio{resource_id="your-function-id-here"} > 90` + + Description + + : Function `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available CPU since 10m. + + **AnyFunctionHighMemoryUsage** + + Pending period + + : 10m + + Summary + + : High memory usage for function `{{ $labels.resource_name }}`. + + Query and alert condition + + : `(serverless_function_memory_usage_bytes / serverless_function_memory_limit_bytes) * 100 > 90` + + Description + + : Function `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available RAM since 10m. + + **FunctionHighMemoryUsage** + + Pending period + + : 10m + + Summary + + : High memory usage for function `{{ $labels.resource_name }}`. + + Query and alert condition + + : `(serverless_function_memory_usage_bytes{resource_id="your-container-id-here"} / serverless_function_memory_limit_bytes{resource_id="your-container-id-here"}) * 100 > 90` + + Description + + : Function `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available RAM since 10m. 8. Select labels that apply to the metric you have selected in the previous step, to target your desired resources and fine-tune your alert. 9. Select one or more values for your labels. From 9bed74198e3f90f9d739947f9ad09d0e2f4ceabe Mon Sep 17 00:00:00 2001 From: SamyOubouaziz Date: Thu, 13 Feb 2025 15:02:30 +0100 Subject: [PATCH 3/7] docs(srv): update --- .../how-to/configure-alerts-jobs.mdx | 158 ++++++++++++++++++ 1 file changed, 158 insertions(+) create mode 100644 pages/serverless-jobs/how-to/configure-alerts-jobs.mdx diff --git a/pages/serverless-jobs/how-to/configure-alerts-jobs.mdx b/pages/serverless-jobs/how-to/configure-alerts-jobs.mdx new file mode 100644 index 0000000000..4469979ae4 --- /dev/null +++ b/pages/serverless-jobs/how-to/configure-alerts-jobs.mdx @@ -0,0 +1,158 @@ +--- +meta: + title: How to add alerts to a job + description: Learn how to add monitoring alerts to Serverless Jobs with Scaleway. +content: + h1: How to add alerts to a job + paragraph: Learn how to add monitoring alerts to Serverless Jobs with Scaleway. +tags: jobs alerts grafana threshold monitoring cockpit +dates: + validation: 2025-02-10 + posted: 2025-02-10 +categories: + - serverless +--- + +This page shows you how to configure alerts for Scaleway Serverless Jobs using Scaleway Cockpit and Grafana. + + + + - A Scaleway account logged into the [console](https://console.scaleway.com) + - [Owner](/iam/concepts/#owner) status or [IAM permissions](/iam/concepts/#permission) allowing you to perform actions in the intended Organization + - Scaleway resources you can monitor + - [Created Grafana credentials](/cockpit/how-to/retrieve-grafana-credentials/) with the **Editor** role + - [Enabled](/cockpit/how-to/enable-alert-manager/) the alert manager, and [activated preconfigured alerts](/cockpit/how-to/activate-managed-alerts/) + - [Created](/cockpit/how-to/add-contact-points/) at least one contact point + - Selected the **Scaleway Alerting** alert manager in Grafana + +1. [Log in to Grafana](/cockpit/how-to/access-grafana-and-managed-dashboards/) using your credentials. +2. Click the **Toggle menu** then click **Alerting**. +3. Click **Alert rules** and **+ New alert rule**. +4. Scroll down to the **Define query and alert condition** section and click **Switch to data source-managed alert rule**. + + This allows you to configure alert rules managed by the data source of your choice, instead of using Grafana's managed alert rules. + + +5. Type in a name for your alert. +6. Select the data source you want to configure alerts for. For the sake of this documentation, we are choosing the **Scaleway Metrics** data source. +7. In the Metrics browser drop-down, select the metric you want to configure an alert for. Refer to the table below for details on each alert for Serverless Jobs. + +**AnyJobError** + +Pending period + +: 5s + +Summary + +: Job run `{{ $labels.resource_id }}` is in error. + +Query and alert condition + +: `(serverless_job_run:state_failed == 1)` OR `(serverless_job_run:state_internal_error == 1)` + +Description + +: Job run `{{ $labels.resource_id }}` from the job def `{{ $labels.resource_name }}` finish in error. Check the console to find out the error message. + +**JobError** + +Pending period + +: 5s + +Summary + +: Job run `{{ $labels.resource_id }}` is in error. + +Query and alert condition + +: `(serverless_job_run:state_failed{resource_name="your-job-name-here"} == 1)` OR `(serverless_job_run:state_internal_error{resource_name="your-job-name-here"} == 1)` + +Description + +: Job run `{{ $labels.resource_id }}` from the job def `{{ $labels.resource_name }}` finish in error. Check the console to find out the error message. + +**AnyJobHighCPUUsage** + +Pending period + +: 10s + +Summary + +: High CPU usage for job run `{{ $labels.resource_id }}`. + +Query and alert condition + +: `serverless_job_run:cpu_usage_seconds_total:rate30s / serverless_job_run:cpu_limit * 100 > 90` + +Description + +: Job run `{{ $labels.resource_name }}` from the job def `{{ $labels.resource_name }}` is using more than `{{ printf "%.0f" $value }}`% of its available CPU since 10s. + +**JobHighCPUUsage** + +Pending period + +: 10s + +Summary + +: High CPU usage for job run `{{ $labels.resource_id }}`. + +Query and alert condition + +: `serverless_job_run:cpu_usage_seconds_total:rate30s{resource_name="your-job-name-here"} / serverless_job_run:cpu_limit{resource_name="your-job-name-here"} * 100 > 90` + +Description + +: Job run `{{ $labels.resource_name }}` from the job def `{{ $labels.resource_name }}` is using more than `{{ printf "%.0f" $value }}`% of its available CPU since 10s. + +**AnyJobHighMemoryUsage** + +Pending period + +: 10s + +Summary + +: High memory usage for job run `{{ $labels.resource_id }}`. + +Query and alert condition + +: `(serverless_job_run:memory_usage_bytes / serverless_job_run:memory_limit_bytes ) * 100 > 80` + +Description + +: Job run `{{ $labels.resource_name }}` from the job def `{{ $labels.resource_name }}` is using more than `{{ printf "%.0f" $value }}`% of its available RAM since 10s. + +**JobHighMemoryUsage** + +Pending period + +: 10s + +Summary + +: High memory usage for job run `{{ $labels.resource_id }}`. + +Query and alert condition + +: `(serverless_job_run:memory_usage_bytes{resource_id="your-job-name-here"} / serverless_job_run:memory_limit_bytes{resource_id="your-job-name-here"}) * 100 > 80` + +Description + +: Job run `{{ $labels.resource_name }}` from the job def `{{ $labels.resource_name }}` is using more than `{{ printf "%.0f" $value }}`% of its available RAM since 10s. + +8. Select labels that apply to the metric you have selected in the previous step, to target your desired resources and fine-tune your alert. +9. Select one or more values for your labels. +10. Click **Use query** to generate your alert based on the conditions you have defined. +11. Select a folder to store your rule, or create a new one. Folders allow you to easily manage your different rules. +12. Select an evaluation group to add your rule to. Rules within the same group are evaluated sequentially over the same time interval. +13. In the **Set alert evaluation behavior** field, configure the amount of time during which the alert can be in breach of the condition(s) you have defined until it triggers. + + For example, if you wish to be alerted after your alert has been in breach of the condition for 2 minutes without interruption, type `2` and select `minutes` in the drop-down. + +14. Optionally, add a summary and a description. +15. Click **Save rule** at the top right corner of your screen to save your alert. Once your alert meets the requirements you have configured, you will receive an email to inform you that your alert has triggered. From c191f35965bbcd31e7c4afd4a305b404524064a1 Mon Sep 17 00:00:00 2001 From: SamyOubouaziz Date: Tue, 18 Feb 2025 17:17:35 +0100 Subject: [PATCH 4/7] docs(srv): update --- .../how-to/configure-alerts-containers.mdx | 12 ++++++------ .../how-to/configure-alerts-function.mdx | 12 ++++++------ 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/pages/serverless-containers/how-to/configure-alerts-containers.mdx b/pages/serverless-containers/how-to/configure-alerts-containers.mdx index 66b63a5a7e..53a3916c96 100644 --- a/pages/serverless-containers/how-to/configure-alerts-containers.mdx +++ b/pages/serverless-containers/how-to/configure-alerts-containers.mdx @@ -53,7 +53,7 @@ This page shows you how to configure alerts for Scaleway Serverless Containers u Description - : Container `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is in error. Check the console to find out the error message. + : Container `{{ $labels.resource_name }}` with ID `{{ $labels.resource_id }}` is in error. Check the console to find out the error message. **ContainerError** @@ -71,7 +71,7 @@ This page shows you how to configure alerts for Scaleway Serverless Containers u Description - : Container `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is in error. Check the console to find out the error message. + : Container `{{ $labels.resource_name }}` with ID `{{ $labels.resource_id }}` is in error. Check the console to find out the error message. **AnyContainerHighCPUUsage** @@ -89,7 +89,7 @@ This page shows you how to configure alerts for Scaleway Serverless Containers u Description - : Container `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available CPU since 10m. + : Container `{{ $labels.resource_name }}` with ID `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available CPU since 10m. **ContainerHighCPUUsage** @@ -107,7 +107,7 @@ This page shows you how to configure alerts for Scaleway Serverless Containers u Description - : Container `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available CPU since 10m. + : Container `{{ $labels.resource_name }}` with ID `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available CPU since 10m. **AnyContainerHighMemoryUsage** @@ -125,7 +125,7 @@ This page shows you how to configure alerts for Scaleway Serverless Containers u Description - : Container `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available RAM since 10m. + : Container `{{ $labels.resource_name }}` with ID `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available RAM since 10m. **ContainerHighMemoryUsage** @@ -143,7 +143,7 @@ This page shows you how to configure alerts for Scaleway Serverless Containers u Description - : Container `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available RAM since 10m. + : Container `{{ $labels.resource_name }}` with ID `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available RAM since 10m. 8. Select labels that apply to the metric you have selected in the previous step, to target your desired resources and fine-tune your alert. 9. Select one or more values for your labels. diff --git a/pages/serverless-functions/how-to/configure-alerts-function.mdx b/pages/serverless-functions/how-to/configure-alerts-function.mdx index 957071ee69..7a8ca79227 100644 --- a/pages/serverless-functions/how-to/configure-alerts-function.mdx +++ b/pages/serverless-functions/how-to/configure-alerts-function.mdx @@ -53,7 +53,7 @@ This page shows you how to configure alerts for Scaleway Serverless Functions us Description - : Function `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is in error. Check the console to find out the error message. + : Function `{{ $labels.resource_name }}` with ID `{{ $labels.resource_id }}` is in error. Check the console to find out the error message. **FunctionError** @@ -71,7 +71,7 @@ This page shows you how to configure alerts for Scaleway Serverless Functions us Description - : Function `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is in error. Check the console to find out the error message. + : Function `{{ $labels.resource_name }}` with ID `{{ $labels.resource_id }}` is in error. Check the console to find out the error message. **AnyFunctionHighCPUUsage** @@ -89,7 +89,7 @@ This page shows you how to configure alerts for Scaleway Serverless Functions us Description - : Function `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available CPU since 10m. + : Function `{{ $labels.resource_name }}` with ID `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available CPU since 10m. **FunctionHighCPUUsage** @@ -107,7 +107,7 @@ This page shows you how to configure alerts for Scaleway Serverless Functions us Description - : Function `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available CPU since 10m. + : Function `{{ $labels.resource_name }}` with ID `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available CPU since 10m. **AnyFunctionHighMemoryUsage** @@ -125,7 +125,7 @@ This page shows you how to configure alerts for Scaleway Serverless Functions us Description - : Function `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available RAM since 10m. + : Function `{{ $labels.resource_name }}` with ID `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available RAM since 10m. **FunctionHighMemoryUsage** @@ -143,7 +143,7 @@ This page shows you how to configure alerts for Scaleway Serverless Functions us Description - : Function `{{ $labels.resource_name }}` with id `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available RAM since 10m. + : Function `{{ $labels.resource_name }}` with ID `{{ $labels.resource_id }}` is using more than `{{ printf "%.0f" $value }}`% of its available RAM since 10m. 8. Select labels that apply to the metric you have selected in the previous step, to target your desired resources and fine-tune your alert. 9. Select one or more values for your labels. From da60bc660a3037dc375d855b540f72b3e543010a Mon Sep 17 00:00:00 2001 From: SamyOubouaziz Date: Fri, 21 Feb 2025 10:52:19 +0100 Subject: [PATCH 5/7] docs(srv): update --- .../how-to/configure-alerts-containers.mdx | 2 +- .../how-to/configure-alerts-function.mdx | 2 +- .../how-to/configure-alerts-jobs.mdx | 18 +++++++++--------- 3 files changed, 11 insertions(+), 11 deletions(-) diff --git a/pages/serverless-containers/how-to/configure-alerts-containers.mdx b/pages/serverless-containers/how-to/configure-alerts-containers.mdx index 53a3916c96..8c62b5f1ef 100644 --- a/pages/serverless-containers/how-to/configure-alerts-containers.mdx +++ b/pages/serverless-containers/how-to/configure-alerts-containers.mdx @@ -21,7 +21,7 @@ This page shows you how to configure alerts for Scaleway Serverless Containers u - [Owner](/iam/concepts/#owner) status or [IAM permissions](/iam/concepts/#permission) allowing you to perform actions in the intended Organization - Scaleway resources you can monitor - [Created Grafana credentials](/cockpit/how-to/retrieve-grafana-credentials/) with the **Editor** role - - [Enabled](/cockpit/how-to/enable-alert-manager/) the alert manager, and [activated preconfigured alerts](/cockpit/how-to/activate-managed-alerts/) + - [Enabled](/cockpit/how-to/enable-alert-manager/) the alert manager - [Created](/cockpit/how-to/add-contact-points/) at least one contact point - Selected the **Scaleway Alerting** alert manager in Grafana diff --git a/pages/serverless-functions/how-to/configure-alerts-function.mdx b/pages/serverless-functions/how-to/configure-alerts-function.mdx index 7a8ca79227..6316010303 100644 --- a/pages/serverless-functions/how-to/configure-alerts-function.mdx +++ b/pages/serverless-functions/how-to/configure-alerts-function.mdx @@ -21,7 +21,7 @@ This page shows you how to configure alerts for Scaleway Serverless Functions us - [Owner](/iam/concepts/#owner) status or [IAM permissions](/iam/concepts/#permission) allowing you to perform actions in the intended Organization - Scaleway resources you can monitor - [Created Grafana credentials](/cockpit/how-to/retrieve-grafana-credentials/) with the **Editor** role - - [Enabled](/cockpit/how-to/enable-alert-manager/) the alert manager, and [activated preconfigured alerts](/cockpit/how-to/activate-managed-alerts/) + - [Enabled](/cockpit/how-to/enable-alert-manager/) the alert manager - [Created](/cockpit/how-to/add-contact-points/) at least one contact point - Selected the **Scaleway Alerting** alert manager in Grafana diff --git a/pages/serverless-jobs/how-to/configure-alerts-jobs.mdx b/pages/serverless-jobs/how-to/configure-alerts-jobs.mdx index 4469979ae4..38e04ca04d 100644 --- a/pages/serverless-jobs/how-to/configure-alerts-jobs.mdx +++ b/pages/serverless-jobs/how-to/configure-alerts-jobs.mdx @@ -21,7 +21,7 @@ This page shows you how to configure alerts for Scaleway Serverless Jobs using S - [Owner](/iam/concepts/#owner) status or [IAM permissions](/iam/concepts/#permission) allowing you to perform actions in the intended Organization - Scaleway resources you can monitor - [Created Grafana credentials](/cockpit/how-to/retrieve-grafana-credentials/) with the **Editor** role - - [Enabled](/cockpit/how-to/enable-alert-manager/) the alert manager, and [activated preconfigured alerts](/cockpit/how-to/activate-managed-alerts/) + - [Enabled](/cockpit/how-to/enable-alert-manager/) the alert manager - [Created](/cockpit/how-to/add-contact-points/) at least one contact point - Selected the **Scaleway Alerting** alert manager in Grafana @@ -53,7 +53,7 @@ Query and alert condition Description -: Job run `{{ $labels.resource_id }}` from the job def `{{ $labels.resource_name }}` finish in error. Check the console to find out the error message. +: Job run `{{ $labels.resource_id }}` from the job definition `{{ $labels.resource_name }}` finish in error. Check the console to find out the error message. **JobError** @@ -71,7 +71,7 @@ Query and alert condition Description -: Job run `{{ $labels.resource_id }}` from the job def `{{ $labels.resource_name }}` finish in error. Check the console to find out the error message. +: Job run `{{ $labels.resource_id }}` from the job definition `{{ $labels.resource_name }}` finish in error. Check the console to find out the error message. **AnyJobHighCPUUsage** @@ -89,7 +89,7 @@ Query and alert condition Description -: Job run `{{ $labels.resource_name }}` from the job def `{{ $labels.resource_name }}` is using more than `{{ printf "%.0f" $value }}`% of its available CPU since 10s. +: Job run `{{ $labels.resource_name }}` from the job definition `{{ $labels.resource_name }}` is using more than `{{ printf "%.0f" $value }}`% of its available CPU since 10s. **JobHighCPUUsage** @@ -99,7 +99,7 @@ Pending period Summary -: High CPU usage for job run `{{ $labels.resource_id }}`. +: High CPU usage for job run `{{ $labels.resource_job definition }}`. Query and alert condition @@ -107,7 +107,7 @@ Query and alert condition Description -: Job run `{{ $labels.resource_name }}` from the job def `{{ $labels.resource_name }}` is using more than `{{ printf "%.0f" $value }}`% of its available CPU since 10s. +: Job run `{{ $labels.resource_name }}` from the job definition `{{ $labels.resource_name }}` is using more than `{{ printf "%.0f" $value }}`% of its available CPU since 10s. **AnyJobHighMemoryUsage** @@ -117,7 +117,7 @@ Pending period Summary -: High memory usage for job run `{{ $labels.resource_id }}`. +: High memory usage for job run `{{ $labels.resource_job definition }}`. Query and alert condition @@ -125,7 +125,7 @@ Query and alert condition Description -: Job run `{{ $labels.resource_name }}` from the job def `{{ $labels.resource_name }}` is using more than `{{ printf "%.0f" $value }}`% of its available RAM since 10s. +: Job run `{{ $labels.resource_name }}` from the job definition `{{ $labels.resource_name }}` is using more than `{{ printf "%.0f" $value }}`% of its available RAM since 10s. **JobHighMemoryUsage** @@ -143,7 +143,7 @@ Query and alert condition Description -: Job run `{{ $labels.resource_name }}` from the job def `{{ $labels.resource_name }}` is using more than `{{ printf "%.0f" $value }}`% of its available RAM since 10s. +: Job run `{{ $labels.resource_name }}` from the job definition `{{ $labels.resource_name }}` is using more than `{{ printf "%.0f" $value }}`% of its available RAM since 10s. 8. Select labels that apply to the metric you have selected in the previous step, to target your desired resources and fine-tune your alert. 9. Select one or more values for your labels. From 882307dd88c7e39d84fa9dda8d99bde225814c04 Mon Sep 17 00:00:00 2001 From: SamyOubouaziz Date: Fri, 21 Feb 2025 10:53:46 +0100 Subject: [PATCH 6/7] docs(srv): update --- .../reference-content/containers-autoscaling.mdx | 2 +- .../reference-content/functions-autoscaling.mdx | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pages/serverless-containers/reference-content/containers-autoscaling.mdx b/pages/serverless-containers/reference-content/containers-autoscaling.mdx index e7bed35ece..ddb43436c3 100644 --- a/pages/serverless-containers/reference-content/containers-autoscaling.mdx +++ b/pages/serverless-containers/reference-content/containers-autoscaling.mdx @@ -26,7 +26,7 @@ This parameter sets the lowest value your resource is allowed to scale down to: - If you set a value of `0`, all instances of your resource will be terminated after 15 minutes of inactivity. -- If you set a value of `1` or more, the corresponding number of instances of your resource will remain available at all time. +- If you set a value of `1` or more, the corresponding number of instances of your resource will remain available at all times. Customizing the minimum scale for Serverless can help ensure that an instance remains pre-allocated and ready to handle requests, reducing delays associated with [cold starts](/serverless-containers/concepts/#cold-start). However, this setting also impacts the costs of your Serverless Container. diff --git a/pages/serverless-functions/reference-content/functions-autoscaling.mdx b/pages/serverless-functions/reference-content/functions-autoscaling.mdx index 3db3e13935..abffd8a5ba 100644 --- a/pages/serverless-functions/reference-content/functions-autoscaling.mdx +++ b/pages/serverless-functions/reference-content/functions-autoscaling.mdx @@ -26,7 +26,7 @@ This parameter sets the lowest value your resource is allowed to scale down to: - If you set a value of `0`, all instances of your resource will be terminated after 15 minutes of inactivity. -- If you set a value of `1` or more, the corresponding number of instances of your resource will remain available at all time. +- If you set a value of `1` or more, the corresponding number of instances of your resource will remain available at all times. Customizing the minimum scale for Serverless can help ensure that an instance remains pre-allocated and ready to handle requests, reducing delays associated with [cold starts](/serverless-functions/concepts/#cold-start). However, this setting also impacts the costs of your Serverless Function. From 5444f4b43344b39ef503dce3e08ab8ba4256f28a Mon Sep 17 00:00:00 2001 From: SamyOubouaziz Date: Thu, 27 Feb 2025 10:45:21 +0100 Subject: [PATCH 7/7] Apply suggestions from code review Co-authored-by: Jessica <113192637+jcirinosclwy@users.noreply.github.com> --- .../how-to/configure-alerts-containers.mdx | 2 +- pages/serverless-functions/how-to/configure-alerts-function.mdx | 2 +- pages/serverless-jobs/how-to/configure-alerts-jobs.mdx | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/pages/serverless-containers/how-to/configure-alerts-containers.mdx b/pages/serverless-containers/how-to/configure-alerts-containers.mdx index 8c62b5f1ef..74789eeaf6 100644 --- a/pages/serverless-containers/how-to/configure-alerts-containers.mdx +++ b/pages/serverless-containers/how-to/configure-alerts-containers.mdx @@ -155,4 +155,4 @@ This page shows you how to configure alerts for Scaleway Serverless Containers u For example, if you wish to be alerted after your alert has been in breach of the condition for 2 minutes without interruption, type `2` and select `minutes` in the drop-down. 14. Optionally, add a summary and a description. -15. Click **Save rule** at the top right corner of your screen to save your alert. Once your alert meets the requirements you have configured, you will receive an email to inform you that your alert has triggered. +15. Click **Save rule** at the top right corner of your screen to save your alert. Once your alert meets the requirements you have configured, you will receive an email to inform you that your alert has been triggered. diff --git a/pages/serverless-functions/how-to/configure-alerts-function.mdx b/pages/serverless-functions/how-to/configure-alerts-function.mdx index 6316010303..8cb4ac29e1 100644 --- a/pages/serverless-functions/how-to/configure-alerts-function.mdx +++ b/pages/serverless-functions/how-to/configure-alerts-function.mdx @@ -155,4 +155,4 @@ This page shows you how to configure alerts for Scaleway Serverless Functions us For example, if you wish to be alerted after your alert has been in breach of the condition for 2 minutes without interruption, type `2` and select `minutes` in the drop-down. 14. Optionally, add a summary and a description. -15. Click **Save rule** at the top right corner of your screen to save your alert. Once your alert meets the requirements you have configured, you will receive an email to inform you that your alert has triggered. +15. Click **Save rule** at the top right corner of your screen to save your alert. Once your alert meets the requirements you have configured, you will receive an email to inform you that your alert has been triggered. diff --git a/pages/serverless-jobs/how-to/configure-alerts-jobs.mdx b/pages/serverless-jobs/how-to/configure-alerts-jobs.mdx index 38e04ca04d..6c1557e7f9 100644 --- a/pages/serverless-jobs/how-to/configure-alerts-jobs.mdx +++ b/pages/serverless-jobs/how-to/configure-alerts-jobs.mdx @@ -155,4 +155,4 @@ Description For example, if you wish to be alerted after your alert has been in breach of the condition for 2 minutes without interruption, type `2` and select `minutes` in the drop-down. 14. Optionally, add a summary and a description. -15. Click **Save rule** at the top right corner of your screen to save your alert. Once your alert meets the requirements you have configured, you will receive an email to inform you that your alert has triggered. +15. Click **Save rule** at the top right corner of your screen to save your alert. Once your alert meets the requirements you have configured, you will receive an email to inform you that your alert has been triggered.