Hi all,
I have the following tick template 

var instance string
var machine_name string
stream
    |from()
        .database('tech')
        .retentionPolicy('autogen')
        .measurement('passenger_queue')
        .where(lambda: "host" == instance)
    |log()
    |alert()
         .id('Passenger queue kapacitor alert')
         .message('{{ .ID }}, Level: {{ .Level }} , Alert Time : {{.Time}}')
         .details('''
          <p>Name of the machine : {{ machine_name }}</p>
          <p>Length of passenger queue : {{ index .Fields "value" }} </p>
       ''')
       .info(lambda: "value" > 30)
       .warn(lambda: "value" > 45)
       .crit(lambda: "value" > 60)
       .stateChangesOnly()
       .email()

my json file looks like this
{
    "instance": {"type" : "string", "value" : "172.30.0.7" },
    "machine_name": {"type" : "string", "value" : "prod2" }
}


is there a way to use machine_name variable in alert
please help

-- 

-- 
Remember to include the version number!
--- 
You received this message because you are subscribed to the Google Groups 
"InfluxData" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/influxdb.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/influxdb/9561ba8e-a507-4110-9658-29398ff6d135%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to