You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Happen the error in class LongFieldMapper.java in the method parsevalue(). The cause of error is a NumberFormatExpcetion, becuase the value(xyzzy) arrive in the method is String.
java.lang.NumberFormatException: For input string: "xyzzy"
eltu
added a commit
to eltu/elasticsearch
that referenced
this issue
Sep 30, 2013
A lenient multi_match query with a boosted field with type mismatch crashes. Simple example:
curl -XPUT http://localhost:9200/blog/post/1?pretty=1 -d '{"foo":123, "bar":"xyzzy"}'
curl -XGET http://localhost:9200/blog/post/_count?pretty=1 -d '{"multi_match": {"fields": ["foo^2", "bar"], "lenient": true, "query": "xyzzy"}}' # crashes with NullPointerException
Interestingly, it works for internal _id field:
curl -XGET http://localhost:9200/blog/post/_count?pretty=1 -d '{"multi_match": {"fields": ["_id^2", "bar"], "lenient": true, "query": "xyzzy"}}' # works
And it doesn't crash when there's no type mismatch:
curl -XGET http://localhost:9200/blog/post/_count?pretty=1 -d '{"multi_match": {"fields": ["foo^2", "bar"], "lenient": true, "query": "123"}}' # works
Other queries for reference:
curl -XGET http://localhost:9200/blog/post/_count?pretty=1 -d '{"multi_match": {"fields": ["foo", "bar"], "lenient": true, "query": "xyzzy"}}' # works
curl -XGET http://localhost:9200/blog/post/_count?pretty=1 -d '{"multi_match": {"fields": ["foo", "bar"], "query": "xyzzy"}}' # crashes with NumberFormatException - expected
The text was updated successfully, but these errors were encountered: