All params should be optional for ngram tokenizer and edge ngram tokenizer #877
Labels
Area: Specification
Related to the API spec used to generate client code
Category: Bug
Something isn't working
Java API client version
8.14.3
Java version
17
Elasticsearch Version
8.14.3
Problem description
Hello! I'm running into a
MissingRequiredPropertyException
when trying to create indices that use ngram/edge ngram tokenizers with the Java client.Minimal code repro - settings are the same as docs but with
token_chars
omitted:throws
Similar example throwing for no maxGram if min_gram/max_gram/token_chars are all omitted
This seems to be because the spec that's used to generate the Java client requires
min_gram
,max_gram
, andtoken_chars
for ngram/edge ngram tokenizers, even though they have defaults in docs (also supported by server code and Lucene defaults).I can also confirm that creating an index via curl without specifying min_gram / max_gram / token_chars works.
returns
The same is true for
"type": "edge_ngram"
as well.The text was updated successfully, but these errors were encountered: