HBase
  1. HBase
  2. HBASE-10186

region_mover.rb broken because ServerName constructor is changed to private

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 0.96.1
    • Fix Version/s: 0.98.0, 0.96.2, 0.99.0
    • Component/s: scripts
    • Labels:
      None
    • Environment:

      x86_64 GNU/Linux

    • Hadoop Flags:
      Reviewed

      Description

      After upgrading to 0.96.1 (from 0.96.0) i have tried rolling restart with ./rolling-restart.sh --graceful but region_mover.rb throws error:

      TypeError: no public constructors for Java::OrgApacheHadoopHbase::ServerName
           getRegions at ./region_mover.rb:257
        unloadRegions at ./region_mover.rb:318
               (root) at ./region_mover.rb:461
      

      After checking region_mover.rb i believe this line:

      return ProtobufUtil::getOnlineRegions(connection.getAdmin(ServerName.new(servername)));
      

      should be changed to

      return ProtobufUtil::getOnlineRegions(connection.getAdmin(ServerName.valueOf(servername)));
      

      After making this change region_mover.rb is working again. I will attach patch shortly.

      1. HBASE-10186.patch
        0.5 kB
        Samir Ahmic

        Issue Links

          Activity

          Samir Ahmic created issue -
          Samir Ahmic made changes -
          Field Original Value New Value
          Description After upgrading to 0.96.1 (from 0.96.0) i have tried rolling restart with ./rolling-restart.sh --graceful but region_mover.sh throws error:
          {code}
          TypeError: no public constructors for Java::OrgApacheHadoopHbase::ServerName
               getRegions at ./region_mover.rb:257
            unloadRegions at ./region_mover.rb:318
                   (root) at ./region_mover.rb:461
          {code}
          After checking region_mover.rb i believe this line:
          {code}
          return ProtobufUtil::getOnlineRegions(connection.getAdmin(ServerName.new(servername)));
          {code}
          should be changed to
          {code}
          return ProtobufUtil::getOnlineRegions(connection.getAdmin(ServerName.valueOf(servername)));
          {code}
          After making this change region_mover.rb is working again. I will attach patch shortly.
          After upgrading to 0.96.1 (from 0.96.0) i have tried rolling restart with ./rolling-restart.sh --graceful but region_mover.rb throws error:
          {code}
          TypeError: no public constructors for Java::OrgApacheHadoopHbase::ServerName
               getRegions at ./region_mover.rb:257
            unloadRegions at ./region_mover.rb:318
                   (root) at ./region_mover.rb:461
          {code}
          After checking region_mover.rb i believe this line:
          {code}
          return ProtobufUtil::getOnlineRegions(connection.getAdmin(ServerName.new(servername)));
          {code}
          should be changed to
          {code}
          return ProtobufUtil::getOnlineRegions(connection.getAdmin(ServerName.valueOf(servername)));
          {code}
          After making this change region_mover.rb is working again. I will attach patch shortly.
          Samir Ahmic made changes -
          Attachment HBASE-10186.patch [ 12619058 ]
          Jonathan Hsieh made changes -
          Status Open [ 1 ] Resolved [ 5 ]
          Hadoop Flags Reviewed [ 10343 ]
          Fix Version/s 0.98.0 [ 12323143 ]
          Fix Version/s 0.96.2 [ 12325658 ]
          Fix Version/s 0.99.0 [ 12325675 ]
          Resolution Fixed [ 1 ]
          Jonathan Hsieh made changes -
          Link This issue is broken by HBASE-10012 [ HBASE-10012 ]
          Enis Soztutar made changes -
          Status Resolved [ 5 ] Closed [ 6 ]

            People

            • Assignee:
              Samir Ahmic
              Reporter:
              Samir Ahmic
            • Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development