Uploaded image for project: 'Solr'
  1. Solr
  2. SOLR-8174

group.ngroups results are not returned when documents indexed to same shard — with Document routing via composite keys

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Minor
    • Resolution: Unresolved
    • 5.3
    • None
    • search, SolrCloud
    • None

    Description

      System setup —
      It’s a 2 sharded collection with Collection Name - anotherEtailSkus and the two shard core names are : anotherEtailSkus_shard1_replica1, anotherEtailSkus_shard2_replica1

      The collection is created with the following http rest api
      http://localhost:8983/solr/admin/collections?action=CREATE&name=anotherEtailSkus&numShards=2&replicationFactor=1&collection.configName=FileTest&maxShardsPerNode=2&router.name=compositeId

      Sample Documents Indexed —

      {"id":"125!1","groupedItemId_i":"1"} {"id":"7!1","groupedItemId_i":"2"}

      Problem Statement —

      Now, with grouping paramters, on any shard with route param the response of group result is different. One of the shard returns group.ngroups and other does not. Please find the attached screenshot and query for reference in google doc link.

      Group query on a shard with the change in shard core only.

      http://localhost:8983/solr/anotherEtailSkus_shard2_replica1/select?q=*%3A*&fl=id,groupedItemId_i&wt=json&indent=true&group=true&group.format=simple&group.field=groupedItemId_i&group.ngroups=true&group.facet=true&_route_=125!

      -----groups.ngroups are not returned in response

      http://localhost:8983/solr/anotherEtailSkus_shard1_replica1/select?q=*%3A*&fl=id,groupedItemId_i&wt=json&indent=true&group=true&group.format=simple&group.field=groupedItemId_i&group.ngroups=true&group.facet=true&_route_=125!
      ----- group.ngroups are returned.

      Document routing via composite key should have routed documents with same key to same shards thus returning group results correctly— as per link [2]. But is not the case.

      Refer to the below google doc for detailed description.

      https://docs.google.com/document/d/1g3M8sm0xGKJt5u26Qab6qawm5GgMzs58pe76uUoJQwk/edit?usp=sharing

      [2]https://cwiki.apache.org/confluence/display/solr/Result+Grouping#ResultGrouping-DistributedResultGroupingCaveats

      Attachments

        Activity

          People

            Unassigned Unassigned
            rajanimaski rajanimaski
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: