Skip to content

Instantly share code, notes, and snippets.

@tegud
Created January 25, 2015 15:07
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tegud/3e66101560767057a36a to your computer and use it in GitHub Desktop.
Save tegud/3e66101560767057a36a to your computer and use it in GitHub Desktop.
Example of categorising urls via logstash conditionals
if [url_path] =~ /^\/status$/ {
mutate { add_tag => "health-check" }
} else if [url_path] =~ /^\/beacon\// {
mutate { add_tag => "beacon" }
} else {
mutate { add_tag => "content" }
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment