From 0b38d0f480679794b1fc388866d71282de2463fd Mon Sep 17 00:00:00 2001 From: Ben Woodley Date: Wed, 19 Jun 2024 11:25:45 +0200 Subject: [PATCH] feat: add in pubsub valueIfNull optional config Signed-off-by: Benjamin Woodley --- content/docs/2.15/scalers/gcp-pub-sub.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/content/docs/2.15/scalers/gcp-pub-sub.md b/content/docs/2.15/scalers/gcp-pub-sub.md index 801dbc2c3..9427d9bb9 100644 --- a/content/docs/2.15/scalers/gcp-pub-sub.md +++ b/content/docs/2.15/scalers/gcp-pub-sub.md @@ -19,6 +19,7 @@ triggers: mode: "SubscriptionSize" # Optional - Default is SubscriptionSize - SubscriptionSize or OldestUnackedMessageAge aggregation: "sum" # Optional - Only meaningful for distribution-valued metrics value: "5.5" # Optional - Default is 10 + valueIfNull: '0.0' # Optional - Default is "" activationValue: "10.5" # Optional - Default is 0 timeHorizon: "1m" # Optional - Default is 2m and with aggregation 5m # Exactly one of the subscription or topic name options is required @@ -42,6 +43,8 @@ The Google Cloud Platform (GCP) Pub/Sub trigger allows you to scale based on any - `timeHorizon` - Time range for which you want to retrieve the matrics. (Default: `2m` and Default with aggregation field: `5m`) +- `valueIfNull` - Value returned if request returns no timeseries.(Default: `""`, Optional, This value can be a float) + - `subscriptionName` defines the subscription that should be monitored. You can use different formulas: - Just the subscription name, in which case you will reference a subscription from the current project or the one specified in the credentials file used. - Use the full link provided by Google, so that you can reference a subscription that is hosted in another project Eg: `projects/myproject/subscriptions/mysubscription`.