Checked Exception "reference to termsQuery is ambiguous [ERROR]"

1、I think this is an api method error.When you use “QueryBuilders.termsQuery("status", 3,4)” query, an error “reference to termsQuery is ambiguous
[ERROR] both method termsQuery(java.lang.String,double...) in org.elasticsearch.index.query.QueryBuilders and method termsQuery(java.lang.String,java.lang.Object...) in org.elasticsearch.index.query.QueryBuilders ” is reported during compilation;
2、In order to avoid the above problems, we need to change another method “QueryBuilders.termsQuery(“status”, Arrays.asList(3, 4)”;Compilation and query passed completely.
3、This error has nothing to do with elasticsearh itself,so I didn't provide DSL
4、如有不妥,请多多指教!(If there is something wrong, please give me more advice!)

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.