hbase-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ted Yu (JIRA)" <j...@apache.org>
Subject [jira] Created: (HBASE-3657) reduce copying of HRegionInfo's
Date Wed, 16 Mar 2011 18:21:29 GMT
reduce copying of HRegionInfo's

                 Key: HBASE-3657
                 URL: https://issues.apache.org/jira/browse/HBASE-3657
             Project: HBase
          Issue Type: Improvement
            Reporter: Ted Yu
            Assignee: Ted Yu

I looked at calls to this method in AssignmentManager:
  public void assignUserRegions(List<HRegionInfo> regions, List<HServerInfo> servers)
Here is one from AssignmentManager:
      assignUserRegions(Arrays.asList(regions.keySet().toArray(new HRegionInfo[0])), servers);
Here is another from Master:
      this.assignmentManager.assignUserRegions(Arrays.asList(newRegions), servers);

I propose changing the first parameter to HRegionInfo[] so that extra copying can be avoided
- considering that the number of regions in production is high.

A bigger task is to reduce memory footprint of AssignmentManager.

It would eliminate this copy:
  165       public static <T> List<T> asList(T... array) {
  166           return new ArrayList<T>(array);
  167       }

This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

View raw message