Building GCP Alerting

Hi Team, i am facing issue where i need to create a log base alert in gcp for false tractions with key and value as msg-type = 5000 as bad and msg type = 1000 is good , so i want to create alert if 5000 occur 90% of time with 20 min time frame compare to good msg type = 1000 from log. How to do it can any one help ?

1 Like

Hello @gauravmall , Welcome on Googl****e Cloud Community.

Do you have proper filter created so far? Or you need to create it from scratch ?


cheers,
Damian Sztankowski | GDE Googl****e Cloud
LinkedIn | medium.com | Sessionize | Youtube | Developers Profile

Hi @DamianS , yes , we have proper log base filter available to differentiate between false and bad transaction.

good transaction filter
resource.type=“k8s_container”
jsonPayload.message:“MQ_PUT [Channel1]”
AND jsonPayload.message:“"msgStatus" : "5000"”

bad transaction filter
resource.type=“k8s_container”
jsonPayload.message:“MQ_PUT [Channel1]”
AND jsonPayload.message:“"msgStatus" : "1000"”

1 Like

Cool. What is your issue then? Did you’ve created log-based metric and then log-based alert based on that metric ?


cheers,
Damian Sztankowski | GDE Googl****e Cloud
LinkedIn | medium.com | Sessionize | Youtube | Developers Profile

yes, i have create a log base metric for both for good and bad one,
but i am not sure how to create a alert so that every 20 min it will check if 90% of trac having 1000 msg as compare to good one 5000 to get alert

1 Like