We're updating the issue view to help you get more done. 

Field type compatibility checks ignore the analyzer

Description

When targeting a single field but multiple indexes in the same predicate, we used to check that the analyzer assigned to the field in each index is compatible.

We mistakenly removed the check in a previous commit

Let's add some tests, because if we didn't notice this removal, it means tests were missing. Then let's fix the problem.

Note the fix will be harder than the code we removed in the commit mentioned above, because we now have to take into account the fact that analyzers may be overridden.

We will have to something very similar to what Fabio did in https://github.com/hibernate/hibernate-search/pull/1923 for converters: check analyzers early, but not throw an exception immediately: we will just store the information "analyzers are incompatible". Later, when we actually need to use the analyzer, we will check whether the analyzers were overridden: if they were, everything is well and we can forget about the incompatibility; if they aren't we need to throw an exception.

Environment

None

Status

Assignee

Fabio Massimo Ercoli

Reporter

Yoann Rodière

Labels

None

Suitable for new contributors

None

Feedback Requested

None

Fix versions

Priority

Major