solralfrescoalfresco-sharesolr4

SOLR undefined field boolean exception Alfresco


I am having problems with Alfresco Share 5.2 and solr4 search. I did full re-index and server stars without any errors in logs.

When I try to search I get 0 as result, it won't work and in logs this error apears:

2023-03-30 08:55:11,514 ERROR [solr.core.SolrCore] [http-bio-8443-exec-25] org.apache.solr.common.SolrException: undefined field: "boolean@sd@{http://www.adama.com/model/document/1.0}documentStudyNotification" 
at org.apache.solr.schema.IndexSchema.getField(IndexSchema.java:1200) 
at org.apache.solr.request.SimpleFacets.getTermCounts(SimpleFacets.java:393) 
at org.apache.solr.request.SimpleFacets.getTermCounts(SimpleFacets.java:366) 
at org.apache.solr.request.SimpleFacets$2.call(SimpleFacets.java:592) 
at org.apache.solr.request.SimpleFacets$2.call(SimpleFacets.java:583) 
at java.util.concurrent.FutureTask.run(FutureTask.java:266) 
at org.apache.solr.request.SimpleFacets$1.execute(SimpleFacets.java:537) 
at org.apache.solr.request.SimpleFacets.getFacetFieldCounts(SimpleFacets.java:608) 
at org.apache.solr.request.SimpleFacets.getFacetCounts(SimpleFacets.java:264) 
at org.apache.solr.handler.component.FacetComponent.process(FacetComponent.java:107) 
at org.apache.solr.handler.component.AlfrescoSearchHandler.handleRequestBody(AlfrescoSearchHandler.java:319) 
at org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHandlerBase.java:135) 
at org.apache.solr.core.SolrCore.execute(SolrCore.java:1976) 
at org.apache.solr.servlet.SolrDispatchFilter.execute(SolrDispatchFilter.java:777) 
at org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:418) 
at org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:207) 
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) 
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) 
at org.alfresco.web.scripts.servlet.X509ServletFilterBase.doFilter(X509ServletFilterBase.java:144) 
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:241) 
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208) 
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:218) 
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:110) 
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:506) 
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:169) 
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:103) 
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:116) 
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:445) 
at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1115) 
at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:637) 
at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:316) 
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) 
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) 
at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61) 
at java.lang.Thread.run(Thread.java:748)

What could be the problem? Should I change something in my solr config?


Solution

  • I guess it's more or less the same issue for which you created the other questions here on SO (1, 2).

    It looks like you removed models which are still referenced.

    The alfresco solr tracker always requests the available models from the repository on startup. So either you removed cached models on a running solr instance or you removed a model/module (adama) from your alfresco repository although there are still nodes in the repository refererencing this model.

    One technical fix would be a new reindex to not index metadata which has no definition in the repository but you may want to put back the model into the repository config since there are still nodes in Alfresco referencing the http://www.adama.com/model/document/1.0 model. Once the model is back in your repo, the solr tracker will retrieve it on next restart.