Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 6.4, 7.0
    • Component/s: None
    • Security Level: Public (Default Security Level. Issues are Public)
    • Labels:
      None

      Description

      Currently, `HttpSolrCall.getCoreByCollection` always picks the first available leader ( or first replica ) of the first slice. It puts undue pressure on leaders and quite possibly on the wrong ones

      1. SOLR-9736.patch
        13 kB
        Cao Manh Dat
      2. SOLR-9736.patch
        13 kB
        Shalin Shekhar Mangar
      3. SOLR-9736.patch
        13 kB
        Cao Manh Dat
      4. SOLR-9736.patch
        16 kB
        Cao Manh Dat

        Activity

        Hide
        caomanhdat Cao Manh Dat added a comment -

        The first attempt for this issue.

        Show
        caomanhdat Cao Manh Dat added a comment - The first attempt for this issue.
        Hide
        caomanhdat Cao Manh Dat added a comment -

        Cleaner patch for this issue.

        Show
        caomanhdat Cao Manh Dat added a comment - Cleaner patch for this issue.
        Hide
        shalinmangar Shalin Shekhar Mangar added a comment -

        This helps reduce load on leader cores but doesn't solve the real problem which is that we might still send the request to the wrong leader. But this is a good first step.

        I updated the patch to add basic javadocs on the new methods in DocCollection as well as on the new RandomIterator class.

        Show
        shalinmangar Shalin Shekhar Mangar added a comment - This helps reduce load on leader cores but doesn't solve the real problem which is that we might still send the request to the wrong leader. But this is a good first step. I updated the patch to add basic javadocs on the new methods in DocCollection as well as on the new RandomIterator class.
        Hide
        shalinmangar Shalin Shekhar Mangar added a comment -

        Upon beasting the new test, I found a reproducible failure:

        ant test  -Dtestcase=HttpSolrCallGetCoreTest -Dtests.method=test -Dtests.seed=9083D720C9C2C732 -Dtests.locale=es-CU -Dtests.timezone=America/Guatemala -Dtests.asserts=true -Dtests.file.encoding=UTF-8
        

        Dat, can you please take a look?

        Show
        shalinmangar Shalin Shekhar Mangar added a comment - Upon beasting the new test, I found a reproducible failure: ant test -Dtestcase=HttpSolrCallGetCoreTest -Dtests.method=test -Dtests.seed=9083D720C9C2C732 -Dtests.locale=es-CU -Dtests.timezone=America/Guatemala -Dtests.asserts= true -Dtests.file.encoding=UTF-8 Dat, can you please take a look?
        Hide
        caomanhdat Cao Manh Dat added a comment - - edited

        Shalin Shekhar Mangar Thank you for review my patch, because the cores are chosen randomly so we can miss some core is chosen in the test.

        Updated patch, in this patch I modified the test to run more request, to make sure that all the
        cores are chosen ( I ran the test about 300 times and it still passed )

        Show
        caomanhdat Cao Manh Dat added a comment - - edited Shalin Shekhar Mangar Thank you for review my patch, because the cores are chosen randomly so we can miss some core is chosen in the test. Updated patch, in this patch I modified the test to run more request, to make sure that all the cores are chosen ( I ran the test about 300 times and it still passed )
        Hide
        jira-bot ASF subversion and git services added a comment -

        Commit 0d290ae136b246918eb8e7257a2197cee9910199 in lucene-solr's branch refs/heads/master from Shalin Shekhar Mangar
        [ https://git-wip-us.apache.org/repos/asf?p=lucene-solr.git;h=0d290ae ]

        SOLR-9736: Solr resolves the collection name against the first available leader or first replica of the first slice

        Show
        jira-bot ASF subversion and git services added a comment - Commit 0d290ae136b246918eb8e7257a2197cee9910199 in lucene-solr's branch refs/heads/master from Shalin Shekhar Mangar [ https://git-wip-us.apache.org/repos/asf?p=lucene-solr.git;h=0d290ae ] SOLR-9736 : Solr resolves the collection name against the first available leader or first replica of the first slice
        Hide
        jira-bot ASF subversion and git services added a comment -

        Commit eedc284c4d45bf26bca8b92e7a86a45b0c9e2330 in lucene-solr's branch refs/heads/branch_6x from Shalin Shekhar Mangar
        [ https://git-wip-us.apache.org/repos/asf?p=lucene-solr.git;h=eedc284 ]

        SOLR-9736: Solr resolves the collection name against the first available leader or first replica of the first slice

        (cherry picked from commit 0d290ae)

        Show
        jira-bot ASF subversion and git services added a comment - Commit eedc284c4d45bf26bca8b92e7a86a45b0c9e2330 in lucene-solr's branch refs/heads/branch_6x from Shalin Shekhar Mangar [ https://git-wip-us.apache.org/repos/asf?p=lucene-solr.git;h=eedc284 ] SOLR-9736 : Solr resolves the collection name against the first available leader or first replica of the first slice (cherry picked from commit 0d290ae)
        Hide
        shalinmangar Shalin Shekhar Mangar added a comment -

        Thanks Dat!

        Show
        shalinmangar Shalin Shekhar Mangar added a comment - Thanks Dat!

          People

          • Assignee:
            shalinmangar Shalin Shekhar Mangar
            Reporter:
            caomanhdat Cao Manh Dat
          • Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development