From b269237c8c819a325ed9ba2787432162a6e51caa Mon Sep 17 00:00:00 2001 From: Yarden Shoham Date: Tue, 7 Mar 2023 09:04:02 +0000 Subject: [PATCH 1/3] Azure Application Insights: Add option to ignore null values Signed-off-by: Yarden Shoham --- content/docs/2.10/scalers/azure-app-insights.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/content/docs/2.10/scalers/azure-app-insights.md b/content/docs/2.10/scalers/azure-app-insights.md index 802221340..4c9cefcd2 100644 --- a/content/docs/2.10/scalers/azure-app-insights.md +++ b/content/docs/2.10/scalers/azure-app-insights.md @@ -30,6 +30,7 @@ triggers: appInsightsResourceURL: https://api.applicationinsights.airgap.io/ # Required when cloud = Private. activeDirectoryEndpoint: https://login.airgap.example/ + ignoreNullValues: false # Default is `true`, which means ignoring any errors with data extraction from a successful query. Set to `false` the scaler will return error when null values are discovered ``` This scaler is backed by the Azure Application Insights REST API. Please see [this](https://docs.microsoft.com/en-us/rest/api/application-insights/metrics/get) page @@ -50,6 +51,7 @@ for further details. - `cloud` - Name of the cloud environment that the Azure Application Insights instance belongs to. (Values: `AzurePublicCloud`, `AzureUSGovernmentCloud`, `AzureChinaCloud`, `Private`, Default: `AzurePublicCloud`, Optional) - `appInsightsResourceURL` - Application Insights REST API URL of the cloud environment. (Required when `cloud` is set to `Private`, e.g. `https://api.applicationinsights.azure.cn/` for `AzureChinaCloud`). - `activeDirectoryEndpoint` - Active Directory endpoint of the cloud environment. (Required when `cloud` is set to `Private`, e.g. `https://login.chinacloudapi.cn/` for `AzureChinaCloud`). +- `ignoreNullValues` - Ignore any errors with data extraction from a successful query (Values: `true`,`false`, Default: `true`, Optional). Some parameters can be provided using environment variables, instead of setting them directly in metadata. Here is a list of parameters you can use to retrieve values from environment variables: From d6e784b8923ad8a44778c85961d432292220058f Mon Sep 17 00:00:00 2001 From: Yarden Shoham Date: Tue, 7 Mar 2023 19:27:28 +0000 Subject: [PATCH 2/3] Change default to false Signed-off-by: Yarden Shoham --- .gitpod.yml | 10 ++++++++++ content/docs/2.10/scalers/azure-app-insights.md | 4 ++-- 2 files changed, 12 insertions(+), 2 deletions(-) create mode 100644 .gitpod.yml diff --git a/.gitpod.yml b/.gitpod.yml new file mode 100644 index 000000000..f3b1c2a85 --- /dev/null +++ b/.gitpod.yml @@ -0,0 +1,10 @@ +# This configuration file was automatically generated by Gitpod. +# Please adjust to your needs (see https://www.gitpod.io/docs/introduction/learn-gitpod/gitpod-yaml) +# and commit this file to your remote git repository to share the goodness with others. + +# Learn more from ready-to-use templates: https://www.gitpod.io/docs/introduction/getting-started/quickstart + +tasks: + - init: npm install && npm run build && make + + diff --git a/content/docs/2.10/scalers/azure-app-insights.md b/content/docs/2.10/scalers/azure-app-insights.md index 4c9cefcd2..7a9891ab1 100644 --- a/content/docs/2.10/scalers/azure-app-insights.md +++ b/content/docs/2.10/scalers/azure-app-insights.md @@ -30,7 +30,7 @@ triggers: appInsightsResourceURL: https://api.applicationinsights.airgap.io/ # Required when cloud = Private. activeDirectoryEndpoint: https://login.airgap.example/ - ignoreNullValues: false # Default is `true`, which means ignoring any errors with data extraction from a successful query. Set to `false` the scaler will return error when null values are discovered + ignoreNullValues: true # Default is `false`. Set to `true` to ignore any errors with data extraction from a successful query. Set to `false` the scaler will return error when null values are discovered ``` This scaler is backed by the Azure Application Insights REST API. Please see [this](https://docs.microsoft.com/en-us/rest/api/application-insights/metrics/get) page @@ -51,7 +51,7 @@ for further details. - `cloud` - Name of the cloud environment that the Azure Application Insights instance belongs to. (Values: `AzurePublicCloud`, `AzureUSGovernmentCloud`, `AzureChinaCloud`, `Private`, Default: `AzurePublicCloud`, Optional) - `appInsightsResourceURL` - Application Insights REST API URL of the cloud environment. (Required when `cloud` is set to `Private`, e.g. `https://api.applicationinsights.azure.cn/` for `AzureChinaCloud`). - `activeDirectoryEndpoint` - Active Directory endpoint of the cloud environment. (Required when `cloud` is set to `Private`, e.g. `https://login.chinacloudapi.cn/` for `AzureChinaCloud`). -- `ignoreNullValues` - Ignore any errors with data extraction from a successful query (Values: `true`,`false`, Default: `true`, Optional). +- `ignoreNullValues` - Ignore any errors with data extraction from a successful query (Values: `true`,`false`, Default: `false`, Optional). Some parameters can be provided using environment variables, instead of setting them directly in metadata. Here is a list of parameters you can use to retrieve values from environment variables: From eb6534ad859ae49e4181b5ad1a3ed96a6faf48a4 Mon Sep 17 00:00:00 2001 From: Yarden Shoham Date: Wed, 8 Mar 2023 10:15:09 +0000 Subject: [PATCH 3/3] Remove the auto-generated file from gitpod Signed-off-by: Yarden Shoham --- .gitpod.yml | 10 ---------- 1 file changed, 10 deletions(-) delete mode 100644 .gitpod.yml diff --git a/.gitpod.yml b/.gitpod.yml deleted file mode 100644 index f3b1c2a85..000000000 --- a/.gitpod.yml +++ /dev/null @@ -1,10 +0,0 @@ -# This configuration file was automatically generated by Gitpod. -# Please adjust to your needs (see https://www.gitpod.io/docs/introduction/learn-gitpod/gitpod-yaml) -# and commit this file to your remote git repository to share the goodness with others. - -# Learn more from ready-to-use templates: https://www.gitpod.io/docs/introduction/getting-started/quickstart - -tasks: - - init: npm install && npm run build && make - -