Using ReferenceSearch outputsLucenePropertyIndex This index is deprecated in the log

Avatar

Avatar

tomas1979

Avatar

tomas1979

tomas1979

06-01-2021

Relatively straightforward usage of ReferenceSearch causes my AEM log to be populated by the following warnings

 

org.apache.jackrabbit.oak.plugins.index.lucene.LucenePropertyIndex This index is deprecated: /oak:index/lucene; it is used for query Filter(query=select [jcr:path], [jcr:score], * from [nt:base] as a where contains.... Please change the query or the index definitions.

 

Code snippet:

ReferenceSearch referenceSearch = new ReferenceSearch();
        referenceSearch.setExact(true);
        referenceSearch.setHollow(true);
        Map<String, ReferenceSearch.Info> resultMap = referenceSearch.search(resourceResolver,path);
        return !resultMap.isEmpty();

 

Is this behaviour expected? What can I do to remove the warning? Would you recommend I build my own query to look for references? My objective is to find pages that are orphaned (have no references) which I'm doing by search for all cq:Page nodes in repository and then iterating through them and triggering the search using the snippet above.

Thanks

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar

PuzanovsP

MVP

Avatar

PuzanovsP

MVP

PuzanovsP
MVP

10-01-2021

Hi Tomas,

 

Adobe Folks are aware of this warning, this has been reported to them before. As per latest this warn is being tracked in their own Jira.

 

There is nothing we can do about it right now, except ignoring it and marking it as known in your wiki.

 

Regards,

Peter

Answers (0)