Details

    • Type: Sub-task
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 4.5, 6.0
    • Component/s: None
    • Labels:
      None

      Description

      split off from SOLR-4942...

      • add a new RandomMergePolicy that implements MergePolicy by proxying to another instance selected at creation using one of the LuceneTestCase.new...MergePolicy methods
      • updated test configs to refer to this new MergePolicy
      • borrow the "tests.shardhandler.randomSeed" logic in SolrTestCaseJ4 to give our RandomMergePolicy a consistent seed at runtime.

        Activity

        Hide
        hossman Hoss Man added a comment -

        here's a patch showing what i had in mind.

        Some of the final getter/setter methods in MergePolicy make writing a true proxy class challenging, but i think this works out well enough, and i included some reflection based tests to try and help future proof against the risk of changes being made to the API that result in the class not behaving the same as whatever random impl it wraps.

        Show
        hossman Hoss Man added a comment - here's a patch showing what i had in mind. Some of the final getter/setter methods in MergePolicy make writing a true proxy class challenging, but i think this works out well enough, and i included some reflection based tests to try and help future proof against the risk of changes being made to the API that result in the class not behaving the same as whatever random impl it wraps.
        Hide
        jira-bot ASF subversion and git services added a comment -

        Commit 1508521 from hossman@apache.org in branch 'dev/trunk'
        [ https://svn.apache.org/r1508521 ]

        SOLR-4951: Better randomization of MergePolicy in Solr tests

        Show
        jira-bot ASF subversion and git services added a comment - Commit 1508521 from hossman@apache.org in branch 'dev/trunk' [ https://svn.apache.org/r1508521 ] SOLR-4951 : Better randomization of MergePolicy in Solr tests
        Hide
        jira-bot ASF subversion and git services added a comment -

        Commit 1508552 from hossman@apache.org in branch 'dev/branches/branch_4x'
        [ https://svn.apache.org/r1508552 ]

        SOLR-4951: Better randomization of MergePolicy in Solr tests (merge r1508521)

        Show
        jira-bot ASF subversion and git services added a comment - Commit 1508552 from hossman@apache.org in branch 'dev/branches/branch_4x' [ https://svn.apache.org/r1508552 ] SOLR-4951 : Better randomization of MergePolicy in Solr tests (merge r1508521)
        Hide
        hossman Hoss Man added a comment -

        r1508521 & r1508552

        Show
        hossman Hoss Man added a comment - r1508521 & r1508552
        Hide
        jpountz Adrien Grand added a comment -

        4.5 release -> bulk close

        Show
        jpountz Adrien Grand added a comment - 4.5 release -> bulk close

          People

          • Assignee:
            hossman Hoss Man
            Reporter:
            hossman Hoss Man
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development