Hi Phil,
The error you mention “The website encountered an unexpected error.
Please try again later.” isn't being generated by Solr but by Drupal. We
can't tell from the error text you're providing what the Drupal Solr
plugin is actually sending to Solr as a query I'm afraid: if you could
figure that out, then you could try running it on Solr itself using the
standard Solr API and see if you could reproduce the problem. It's also
certainly possible that your Drupal system is sending something crazy to
Solr which causes the error. You might look into raising the Solr
logging level (see
https://lucene.apache.org/solr/guide/8_5/configuring-logging.html)
Best
Charlie
On 24/03/2020 15:38, Staley, Phil R - DCF wrote:
I just updated to SOLR 8.5.0 on one of our test servers and I continue to get
the same issue/bug I described below. Below my description of the problem I
have also included the log message detail from Drupal.
This is the third time I have submitted this item. For the time being we will
continue to run SOLR 7.7.2 in production.
Thanks,
Phil Staley
Webmaster
Wisconsin Dept. of Childern and Families
608 422-6569
phil.sta...@wisconsin.gov<mailto:phil.sta...@wisconsin.gov>
We recently upgraded to our Drupal 8 sites to SOLR 8.3.1. We are now getting
reports of certain patterns of search terms resulting in an error that reads,
“The website encountered an unexpected error. Please try again later.”
Below is a list of example terms that always result in this error and a similar
list that works fine. The problem pattern seems to be a search term that
contains 2 or 3 characters followed by a space, followed by additional text.
To confirm that the problem is version 8 of SOLR, I have updated our local and
UAT sites with the latest Drupal updates that did include an update to the
Search API Solr module and tested the terms below under SOLR 7.7.2, 8.3.1, and
8.4.1. Under version 7.7.2 everything works fine. Under either of the version
8, the problem returns.
Thoughts?
Search terms that result in error
• w-2 agency directory
• agency w-2 directory
• w-2 agency
• w-2 directory
• w2 agency directory
• w2 agency
• w2 directory
Search terms that do not result in error
• w-22 agency directory
• agency directory w-2
• agency w-2directory
• agencyw-2 directory
• w-2
• w2
• agency directory
• agency • directory
• -2 agency directory
• 2 agency directory
• w-2agency directory
• w2agency directory
Drupal\search_api_solr\SearchApiSolrException: An error occurred while trying to search with Solr: { "error":{
"msg":"0", "trace":"java.lang.ArrayIndexOutOfBoundsException: 0\n\tat
org.apache.lucene.util.QueryBuilder.newSynonymQuery(QueryBuilder.java:701)\n\tat
org.apache.solr.parser.SolrQueryParserBase.newSynonymQuery(SolrQueryParserBase.java:636)\n\tat
org.apache.lucene.util.QueryBuilder.analyzeGraphBoolean(QueryBuilder.java:581)\n\tat
org.apache.lucene.util.QueryBuilder.createFieldQuery(QueryBuilder.java:343)\n\tat
org.apache.lucene.util.QueryBuilder.createFieldQuery(QueryBuilder.java:263)\n\tat
org.apache.solr.parser.SolrQueryParserBase.newFieldQuery(SolrQueryParserBase.java:527)\n\tat
org.apache.solr.parser.QueryParser.newFieldQuery(QueryParser.java:62)\n\tat
org.apache.solr.parser.SolrQueryParserBase.getFieldQuery(SolrQueryParserBase.java:1141)\n\tat
org.apache.solr.parser.QueryParser.MultiTerm(QueryParser.java:593)\n\tat org.apache.solr.parser.QueryParser.Query(QueryParser.java:142)\n\tat
org.apache.solr.parser.QueryParser.Clause(QueryParser.java:282)\n\tat org.apache.solr.parser.QueryParser.Query(QueryParser.java:162)\n\tat
org.apache.solr.parser.QueryParser.Clause(QueryParser.java:282)\n\tat org.apache.solr.parser.QueryParser.Query(QueryParser.java:162)\n\tat
org.apache.solr.parser.QueryParser.Clause(QueryParser.java:282)\n\tat org.apache.solr.parser.QueryParser.Query(QueryParser.java:162)\n\tat
org.apache.solr.parser.QueryParser.TopLevelQuery(QueryParser.java:131)\n\tat
org.apache.solr.parser.SolrQueryParserBase.parse(SolrQueryParserBase.java:263)\n\tat
org.apache.solr.search.LuceneQParser.parse(LuceneQParser.java:49)\n\tat org.apache.solr.search.QParser.getQuery(QParser.java:174)\n\tat
org.apache.solr.handler.component.QueryComponent.prepare(QueryComponent.java:161)\n\tat
org.apache.solr.handler.component.SearchHandler.handleRequestBody(SearchHandler.java:302)\n\tat
org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHandlerBase.java:211)\n\tat
org.apache.solr.core.SolrCore.execute(SolrCore.java:2596)\n\tat org.apache.solr.servlet.HttpSolrCall.execute(HttpSolrCall.java:802)\n\tat
org.apache.solr.servlet.HttpSolrCall.call(HttpSolrCall.java:579)\n\tat
org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:420)\n\tat
org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:352)\n\tat
org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1596)\n\tat
org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:545)\n\tat
org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:143)\n\tat
org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:590)\n\tat
org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127)\n\tat
org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:235)\n\tat
org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:1607)\n\tat
org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:233)\n\tat
org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1297)\n\tat
org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:188)\n\tat
org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:485)\n\tat
org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:1577)\n\tat
org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:186)\n\tat
org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1212)\n\tat
org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141)\n\tat
org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:221)\n\tat
org.eclipse.jetty.server.handler.InetAccessHandler.handle(InetAccessHandler.java:177)\n\tat
org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerCollection.java:146)\n\tat
org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127)\n\tat
org.eclipse.jetty.rewrite.handler.RewriteHandler.handle(RewriteHandler.java:322)\n\tat
org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127)\n\tat
org.eclipse.jetty.server.Server.handle(Server.java:500)\n\tat org.eclipse.jetty.server.HttpChannel.lambda$handle$1(HttpChannel.java:383)\n\tat
org.eclipse.jetty.server.HttpChannel.dispatch(HttpChannel.java:547)\n\tat
org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:375)\n\tat
org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:270)\n\tat
org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:311)\n\tat
org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:103)\n\tat
org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:117)\n\tat
org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:336)\n\tat
org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:313)\n\tat
org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:171)\n\tat
org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:129)\n\tat
org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:388)\n\tat
org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:806)\n\tat
org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:938)\n\tat java.lang.Thread.run(Thread.java:748)\n",
"code":500}} in Drupal\search_api_solr\Plugin\search_api\backend\SearchApiSolrBackend->search() (line 1600 of
/srv/www/dcfinternet/phil/modules/composer/search_api_solr/src/Plugin/search_api/backend/SearchApiSolrBackend.php).
--
Charlie Hull
OpenSource Connections, previously Flax
tel/fax: +44 (0)8700 118334
mobile: +44 (0)7767 825828
web: www.o19s.com