Uploaded image for project: 'Jackrabbit Oak'
  1. Jackrabbit Oak
  2. OAK-3101

wrong use of jcr:score in Solr when sorting

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 1.0.17, 1.2.2, 1.3.2
    • Fix Version/s: 1.0.18, 1.2.3, 1.3.3, 1.4
    • Component/s: solr
    • Labels:
      None

      Description

      When running a query with order by @jcr:score it gets wrongly
      translated into Solr and could, sometimes, cause exceptions on the
      Solr side

      ERROR - 2015-06-22 14:27:34.729; org.apache.solr.common.SolrException; org.apache.solr.common.SolrException: can not sort on multivalued field: jcr\:score_string_sort
      	at org.apache.solr.schema.SchemaField.checkSortability(SchemaField.java:169)
      	at org.apache.solr.schema.FieldType.getStringSort(FieldType.java:683)
      	at org.apache.solr.schema.TextField.getSortField(TextField.java:97)
      	at org.apache.solr.schema.SchemaField.getSortField(SchemaField.java:152)
      	at org.apache.solr.search.QueryParsing.parseSortSpec(QueryParsing.java:369)
      	at org.apache.solr.search.QParser.getSort(QParser.java:247)
      	at org.apache.solr.handler.component.QueryComponent.prepare(QueryComponent.java:175)
      	at org.apache.solr.handler.component.SearchHandler.handleRequestBody(SearchHandler.java:197)
      	at org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHandlerBase.java:135)
      	at org.apache.solr.core.SolrCore.execute(SolrCore.java:1967)
      	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.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1419)
      	at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:455)
      	at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:137)
      	at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:557)
      	at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:231)
      	at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1075)
      	at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:384)
      	at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:193)
      	at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1009)
      	at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:135)
      	at org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:255)
      	at org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerCollection.java:154)
      	at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:116)
      	at org.eclipse.jetty.server.Server.handle(Server.java:368)
      	at org.eclipse.jetty.server.AbstractHttpConnection.handleRequest(AbstractHttpConnection.java:489)
      	at org.eclipse.jetty.server.BlockingHttpConnection.handleRequest(BlockingHttpConnection.java:53)
      	at org.eclipse.jetty.server.AbstractHttpConnection.headerComplete(AbstractHttpConnection.java:942)
      	at org.eclipse.jetty.server.AbstractHttpConnection$RequestHandler.headerComplete(AbstractHttpConnection.java:1004)
      	at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:640)
      	at org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:235)
      	at org.eclipse.jetty.server.BlockingHttpConnection.handle(BlockingHttpConnection.java:72)
      	at org.eclipse.jetty.server.bio.SocketConnector$ConnectorEndPoint.run(SocketConnector.java:264)
      	at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:608)
      	at org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:543)
      	at java.lang.Thread.run(Unknown Source)
      

        Attachments

          Activity

            People

            • Assignee:
              teofili Tommaso Teofili
              Reporter:
              edivad Davide Giannella
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: