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

Collection RENAME api creates broken alias

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 9.0, 8.11.2, 9.1
    • main (10.0), 8.11.3, 9.2
    • None
    • None

    Description

      Renaming a collection results in a broken alias (name as the source param) pointing to a non-existent collection (named as the target param).

      Steps to reproduce:

      • First create a new collection
        bin/solr create -c films -s 2 -rf 2
        
      • Second issue rename call
        > curl -X POST "http://127.0.0.1:8983/solr/admin/collections?action=RENAME&name=films&target=morefilms"
        { "responseHeader":{ "status":0, "QTime":125}}
        

       

      This will create an alias called 'films' pointing to a collection named 'morefilms', when it should be the other way around.

       

      > curl -X GET http://localhost:8983/api/cluster/aliases
      {
        "responseHeader": {
          "status": 0,
          "QTime": 0
        },
        "aliases": {
          "films": "morefilms"
        },
        "properties": {}
      } 

       

       

       

      Attachments

        1. broken-alias.png
          552 kB
          Alex Deparvu

        Issue Links

          Activity

            People

              krisden Kevin Risden
              stillalex Alex Deparvu
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 2h 10m
                  2h 10m