elasticsearch agg

OK

curl -XGET http://21.3.5.121:9200/ipv4geo/service/_count -d '{"query":{"match":{"srv_content":"iis"}}}'

curl -XGET http://21.3.5.121:9200/ipv4geo/service/_search -d '{"aggs":{"group_yy":{"terms":{"field":"countryName"}}}}'

curl -XGET http://21.3.5.121:9200/ipv4geo/service/_search -d '{"query":{"match_all":{"ssh"}},"facets":{"tag":{"terms":{"field":"countryName","size":5}}}}'

curl -XGET http://21.3.5.121:9200/ipv4geo/service/_search -d '{"query":{"match_all":{"ssh"}},"facets":{"tag":{"terms":{"field":"countryName","size":5}}}}'

curl -XGET http://21.3.5.121:9200/ipv4geo/service/_search -d '{"query":{"match":"openssh"},"size":0,"facets":{"ips_stats":{"terms_stats":{"key_field":"countryName","size":5}}}}'

curl -XGET http://21.3.5.121:9200/ipv4geo/service/_search?search_type=count -d '{"query":{"match":{"srv_content":"openssh"}},"aggs":{"countryName":{"terms":{"field":"countryName"}}}}'

OK

curl -XGET http://21.3.5.121:9200/ipv4geo/service/_search?search_type=count -d '{"query":{"match":{"srv_content":"openssh"}},"aggs":{"countryName":{"terms":{"field":"countryName"}}}}'

posted @ 2016-12-08 10:57  蚂蚁都督  阅读(765)  评论(0编辑  收藏  举报