Query Performance: Kibana generated query

The following query takes between 15-20 seconds to
run: https://gist.github.com/ubethke/ddc311dc6036c582eff6

I would expect this to run a lot quicker. Are there any issues with the
query. Could it be written in a more efficient way?

Based on our setup below is this query performance for the type of query

2 instances m3.2xlarge on EC2
Index in question 2 shards and 1 replica
Index in question 190M documents (mostly int,long,double data types)
Index size 40 GB
No custom routing
55% of memory allocated to ES JVM

You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/d827f095-263a-46d8-a21a-62704ec810fc%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.