Solr
  1. Solr
  2. SOLR-7541

CollectionsHandler#createNodeIfNotExists is a duplicate of ZkCmdExecutor#ensureExists

    Details

    • Type: Improvement Improvement
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 5.2, 6.0
    • Component/s: None
    • Labels:
      None

      Description

      Looks like CollectionsHandler#createNodeIfNotExists is a duplicate of ZkCmdExecutor#ensureExists . Both do the same thing so we could remove CollectionsHandler#createNodeIfNotExists.

      Also looking at ZkCmdExecutor#ensureExists(final String path, final byte[] data,CreateMode createMode, final SolrZkClient zkClient) the createMode parameter is getting discarded.

      1. SOLR-7541.patch
        6 kB
        Varun Thacker
      2. SOLR-7541.patch
        5 kB
        Varun Thacker

        Activity

        Hide
        Varun Thacker added a comment -

        Simple patch with attached CHANGES entry. Tests and precommit passes.

        Show
        Varun Thacker added a comment - Simple patch with attached CHANGES entry. Tests and precommit passes.
        Hide
        Varun Thacker added a comment -

        Updated patch to trunk. Tests and precommit are happy. I'll commit this shortly

        Show
        Varun Thacker added a comment - Updated patch to trunk. Tests and precommit are happy. I'll commit this shortly
        Hide
        ASF subversion and git services added a comment -

        Commit 1679568 from Varun Thacker in branch 'dev/trunk'
        [ https://svn.apache.org/r1679568 ]

        SOLR-7541: Removed CollectionsHandler#createNodeIfNotExists. All calls made to this method now call ZkCmdExecutor#ensureExists as they were doing the same thing

        Show
        ASF subversion and git services added a comment - Commit 1679568 from Varun Thacker in branch 'dev/trunk' [ https://svn.apache.org/r1679568 ] SOLR-7541 : Removed CollectionsHandler#createNodeIfNotExists. All calls made to this method now call ZkCmdExecutor#ensureExists as they were doing the same thing
        Hide
        Mark Miller added a comment -

        +1, looks great.

        Show
        Mark Miller added a comment - +1, looks great.
        Hide
        ASF subversion and git services added a comment -

        Commit 1679583 from Varun Thacker in branch 'dev/branches/branch_5x'
        [ https://svn.apache.org/r1679583 ]

        SOLR-7541: Removed CollectionsHandler#createNodeIfNotExists. All calls made to this method now call ZkCmdExecutor#ensureExists as they were doing the same thing (merged from trunk r1679568)

        Show
        ASF subversion and git services added a comment - Commit 1679583 from Varun Thacker in branch 'dev/branches/branch_5x' [ https://svn.apache.org/r1679583 ] SOLR-7541 : Removed CollectionsHandler#createNodeIfNotExists. All calls made to this method now call ZkCmdExecutor#ensureExists as they were doing the same thing (merged from trunk r1679568)
        Hide
        ASF subversion and git services added a comment -

        Commit 1679598 from Varun Thacker in branch 'dev/trunk'
        [ https://svn.apache.org/r1679598 ]

        SOLR-7541: Corrected CHANGES entry. Missed adding credits in the entry

        Show
        ASF subversion and git services added a comment - Commit 1679598 from Varun Thacker in branch 'dev/trunk' [ https://svn.apache.org/r1679598 ] SOLR-7541 : Corrected CHANGES entry. Missed adding credits in the entry
        Hide
        Anshum Gupta added a comment -

        Bulk close for 5.2.0.

        Show
        Anshum Gupta added a comment - Bulk close for 5.2.0.

          People

          • Assignee:
            Varun Thacker
            Reporter:
            Varun Thacker
          • Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development