Cab someone please explain what the following parts of the query do (just the bolded portion, not the entire query). Thanks.
The duration field that is being calculated looks like myapp_duration=0d 0h 0m 0s in the native format.
The whole search:
index=myapp NOT EIT_Net NOT businessUnit=EIT |
eval myapp_duration=replace(replace(replace(myapp_duration,"d\s","+"),"h|m|s",""),"\s",":")
| convert dur2sec(myapp_duration)
| stats avg(myapp_duration) as avg_myapp_duration by severity
| eval avg_myapp_duration=tostring(round(avg_myapp_duration,0),"duration")
| eval severity=case(severity==0,"Cleared",
severity==1,"Intermediate",
severity==2,"Warning",
severity==3,"Maintenance",
severity==4,"Major",
severity==5,"Critical")
| rename severity as Severity
| rename avg_myapp_duration as "Average Duration"
Portion of interest:
eval myapp_duration=replace(replace(replace(myapp_duration,"d\s","+"),"h|m|s",""),"\s",":")
| convert dur2sec(myapp_duration)
| stats avg(myapp_duration) as avg_myapp_duration by severity
| eval avg_myapp_duration=tostring(round(avg_myapp_duration,0),"duration")
... View more