elasticsearch api

count

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

aggs

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-11-09 11:28  蚂蚁都督  阅读(113)  评论(0编辑  收藏  举报