hbase-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "cuijianwei (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (HBASE-12608) region_mover.rb does not log moving region count correctly when loading regions
Date Tue, 02 Dec 2014 03:07:12 GMT

     [ https://issues.apache.org/jira/browse/HBASE-12608?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

cuijianwei updated HBASE-12608:
-------------------------------
    Description: 
region_mover.rb does not seem to log moving region count correctly by the following code:
{code}
    ...
    if currentServer and currentServer == servername
      $LOG.info("Region " + r.getRegionNameAsString() + " (" + count.to_s +
        " of " + regions.length.to_s + ") already on target server=" + servername)
      counter = counter + 1
      next
    end
    pool.launch(r,currentServer,count) do |_r,_currentServer,_count|
      $LOG.info("Moving region " + _r.getRegionNameAsString() + " (" + (_count + 1).to_s +
        " of " + regions.length.to_s + ") from " + _currentServer.to_s + " to server=" +
        servername);
      move(admin, _r, servername, _currentServer)
    end
    counter = counter + 1
{code}
It seems we should use 'counter' when logging and remove the duplicated variable 'count'.

  was:
region_mover.rb does not seem to log moving region count correctly by the following code:
{code}
    ...
    if currentServer and currentServer == servername
      $LOG.info("Region " + r.getRegionNameAsString() + " (" + count.to_s +
        " of " + regions.length.to_s + ") already on target server=" + servername)
      counter = counter + 1
      next
    end
    pool.launch(r,currentServer,count) do |_r,_currentServer,_count|
      $LOG.info("Moving region " + _r.getRegionNameAsString() + " (" + (_count + 1).to_s +
        " of " + regions.length.to_s + ") from " + _currentServer.to_s + " to server=" +
        servername);
      move(admin, _r, servername, _currentServer)
    end
    counter = counter + 1
{code}
It seems we should use {code}counter{code} when logging and remove the duplicated variable
{code}count{code}.


> region_mover.rb does not log moving region count correctly when loading regions
> -------------------------------------------------------------------------------
>
>                 Key: HBASE-12608
>                 URL: https://issues.apache.org/jira/browse/HBASE-12608
>             Project: HBase
>          Issue Type: Improvement
>          Components: shell
>    Affects Versions: 0.98.8
>            Reporter: cuijianwei
>            Priority: Minor
>
> region_mover.rb does not seem to log moving region count correctly by the following code:
> {code}
>     ...
>     if currentServer and currentServer == servername
>       $LOG.info("Region " + r.getRegionNameAsString() + " (" + count.to_s +
>         " of " + regions.length.to_s + ") already on target server=" + servername)
>       counter = counter + 1
>       next
>     end
>     pool.launch(r,currentServer,count) do |_r,_currentServer,_count|
>       $LOG.info("Moving region " + _r.getRegionNameAsString() + " (" + (_count + 1).to_s
+
>         " of " + regions.length.to_s + ") from " + _currentServer.to_s + " to server="
+
>         servername);
>       move(admin, _r, servername, _currentServer)
>     end
>     counter = counter + 1
> {code}
> It seems we should use 'counter' when logging and remove the duplicated variable 'count'.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message