miya1
(SHUSAKU MIYAHARA)
July 11, 2017, 2:20pm
1
I'd like to run it with "suggest" JavaClient below.
{
"suggest": {
"my-suggestion-1": {
"text": "sample",
"completion": {
"field": "suggest1",
"size": 10
}
}
}
}
I could not find the document.
Please let me know the URL of the document.
Also, how should I implement it?
Someone, please lend me your wisdom.
Environment
Language: Java 8
Framework: Spring
*Elasticsearch client (jar) ver
Org.elasticsearch: 5.1.1
Org.elasticsearch.client: 5.1.1
Elasticsearch's ver: 5.3.1
dadoonet
(David Pilato)
July 11, 2017, 3:44pm
2
May be have a look at the Java tests?
Like:
import static org.hamcrest.Matchers.nullValue;
/**
* Integration tests for term and phrase suggestions. Many of these tests many requests that vary only slightly from one another. Where
* possible these tests should declare for the first request, make the request, modify the configuration for the next request, make that
* request, modify again, request again, etc. This makes it very obvious what changes between requests.
*/
public class SuggestSearchIT extends ESIntegTestCase {
// see #3196
public void testSuggestAcrossMultipleIndices() throws IOException {
createIndex("test");
ensureGreen();
index("test", "type1", "1", "text", "abcd");
index("test", "type1", "2", "text", "aacd");
index("test", "type1", "3", "text", "abbd");
index("test", "type1", "4", "text", "abcc");
refresh();
TermSuggestionBuilder termSuggest = termSuggestion("text")
system
(system)
Closed
August 8, 2017, 3:44pm
3
This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.