Search elasticsearch all content from especific source -


i want know if possible search content specific _source in elasticsearch.

for example have this:

{ "_shards":{     "total" : 5,     "successful" : 5,     "failed" : 0 }, "hits":{     "total" : 1,     "hits" : [         {             "_index" : "twitter",             "_type" : "tweet",             "_id" : "1",              "_source" : {                 "user" : "kimchy",                 "postdate" : "2009-11-15t14:12:12",                 "message" : "trying out elastic search"             }         }     ] } 

}

i want query users source without specifying name.

for eg: similar in sql this

select * user twitter 

and give users

thanks , sorry bad english

edit: want search source. give example, have source store random word, store, not. want search source when have new words.

the plan verify last 10 minutes if in specific source have new, if not, don't care

you can just:

$ curl -xget 'http://localhost:9200/twitter/_search' 

that default return 10 documents. can sipecify size:

$ curl -xget 'http://localhost:9200/twitter/_search?size=bignum' 

or can use scrool: https://www.elastic.co/guide/en/elasticsearch/reference/current/search-request-scroll.html


Comments

Popular posts from this blog

magento2 - Magento 2 admin grid add filter to collection -

Android volley - avoid multiple requests of the same kind to the server? -

Combining PHP Registration and Login into one class with multiple functions in one PHP file -