|
Hi Julien, thanks for logging this but unfortunately it's not possible to provide this validation without making significant changes to the API.
We started to improve on this by working on HSEARCH-1984: the aim is that from the next version you'll have to explicitly map which index fields will be a valid sorting option; initially to allow people to migrate from the older model we'll have to - at best - log a warning if the requested sorting was not enabled in advance.
We were working on this also because of other reasons; primarily that with Lucene 5 there will be a performance penalty when the sorting fields are not defined in advance, while this was ok with previous versions of Lucene.
|