Created
July 23, 2015 13:15
-
-
Save demmer/5708c4d7f6cc70ad7969 to your computer and use it in GitHub Desktop.
Combining Inputs with Juttle
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Prompt for a time duration and a threshold parameter | |
input duration: duration -label 'Time period'; | |
input threshold: number -label 'Max response time (ms)' -default 500; | |
// Use these inputs to filter out only hosts that have experienced high response times | |
// during the specified time period. | |
input host: combobox -juttle "read -demo 'srch_cluster' -last :${duration}: name = 'response_ms' | filter value > ${threshold} | reduce by host" | |
-valueField 'host' -label 'Hosts with response time > ${threshold} ms'; | |
// Once a host is selected, show the response time chart | |
read -demo 'srch_cluster' -last duration name='response_ms' host = #host | |
| @timechart -title 'Response time for ${host}' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment