Hi to all, i'm new to ES ;
I'm trying to using the percolate feature with the Java API;
I copied the example in the guide but it doesn't work for me at all;
with version 1 of this code i have a Exception Caused by:
org.elasticsearch.indices.IndexMissingException: [testindex] missing
// on startup
//
Client client = new TransportClient()
.addTransportAddress(new
InetSocketTransportAddress("localhost", 9300))
.addTransportAddress(new
InetSocketTransportAddress("localhost", 9300));
for(String result : response) {
//Handle the result which is the name of
//the query in the percolator
}
client.close();
So if i create a testindex with cURL, the program become idle on
client.preparePercolate("testindex",
"myDocumentType").setSource(docBuilder).execute().actionGet();
and wait forever;
if i use "_percolator" instead of "testindex" i get this following
Exception
Caused by: org.elasticsearch.index.percolator.PercolatorException:
[_percolator] No doc to percolate in the request
I think i'm missing something important.. can somebody help me please?
You have several problems in your code, though the fact that it gets stuck
is strange..., I will try and recreate. In general though, you need to
register a query against the _percoaltor index, with the index name you wish
that query to be registered against.
Hi to all, i'm new to ES ;
I'm trying to using the percolate feature with the Java API;
I copied the example in the guide but it doesn't work for me at all;
with version 1 of this code i have a Exception Caused by:
org.elasticsearch.indices.IndexMissingException: [testindex] missing
// on startup
//
Client client = new TransportClient()
.addTransportAddress(new
InetSocketTransportAddress("localhost", 9300))
.addTransportAddress(new
InetSocketTransportAddress("localhost", 9300));
for(String result : response) {
//Handle the result which is the name of
//the query in the percolator
}
client.close();
So if i create a testindex with cURL, the program become idle on
client.preparePercolate("testindex",
"myDocumentType").setSource(docBuilder).execute().actionGet();
and wait forever;
if i use "_percolator" instead of "testindex" i get this following
Exception
Caused by: org.elasticsearch.index.percolator.PercolatorException:
[_percolator] No doc to percolate in the request
I think i'm missing something important.. can somebody help me please?
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.