ElasticSearch Facet异常处理
当facet时数据返回数字不对,或者出现异常,不做facet不报错,百思不得其解,在独立的index下建index type,facet也不报错。
QueryPhaseExecutionException[[dn][2]: query[ConstantScore(NotDeleted(cache(_type:dn_character_glory)))],from[0],size[1]: Query Failed [Failed to execute main query]]; nested: NumberFormatException[Invalid shift value in prefixCoded string (is encoded value really a LONG?
When you facet on a field across index types, they need to be of the same field type (string, long). You can name the field differently.