hadoop-common-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "stack (JIRA)" <j...@apache.org>
Subject [jira] Updated: (HADOOP-1498) Use primitives -- long, byte [] -- in place of Long, BytesWritable, etc.
Date Sat, 16 Jun 2007 00:43:26 GMT

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

stack updated HADOOP-1498:

    Attachment: primitives.patch

Commit message.

HADOOP-1498 Use primitives -- long, byte [] -- in place of Long,
BytesWritable, etc.

General pattern of changes in the below is:

 + Replace BytesWriable instances with byte [].
 + Remove unnecessary copying of byte arrays.
 + Use ImmutableByteWritable where we need to pass a Comparable.
 + Add in javadoc.
 + New style for loop.
 + Use List instead of Vector where no need of synchronization.

* src/contrib/hbase/src/test/org/apache/hadoop/hbase/TestHMemcache.java
* src/contrib/hbase/src/test/org/apache/hadoop/hbase/TestScanner2.java
* src/contrib/hbase/src/test/org/apache/hadoop/hbase/AbstractMergeTestBase.java
* src/contrib/hbase/src/test/org/apache/hadoop/hbase/TestHLog.java
* src/contrib/hbase/src/test/org/apache/hadoop/hbase/TestScanner.java
* src/contrib/hbase/src/test/org/apache/hadoop/hbase/TestHRegion.java
* src/contrib/hbase/src/java/org/apache/hadoop/hbase/HStore.java
* src/contrib/hbase/src/java/org/apache/hadoop/hbase/HMerge.java
* src/contrib/hbase/src/java/org/apache/hadoop/hbase/HScannerInterface.java
* src/contrib/hbase/src/java/org/apache/hadoop/hbase/HClient.java
* src/contrib/hbase/src/java/org/apache/hadoop/hbase/HRegionServer.java
* src/contrib/hbase/src/java/org/apache/hadoop/hbase/HMaster.java
* src/contrib/hbase/src/java/org/apache/hadoop/hbase/HMemcache.java
* src/contrib/hbase/src/java/org/apache/hadoop/hbase/HRegiondirReader.java
* src/contrib/hbase/src/java/org/apache/hadoop/hbase/HInternalScannerInterface.java
* src/contrib/hbase/src/java/org/apache/hadoop/hbase/HAbstractScanner.java
  All above got the general treatment.

  Below got general treatment plus whatever we call out below.
* src/contrib/hbase/src/test/org/apache/hadoop/hbase/TestHStoreKey.java
  Added extractFamily tests.
* src/contrib/hbase/src/java/org/apache/hadoop/hbase/HLogKey.java
  Added comment.
* src/contrib/hbase/src/java/org/apache/hadoop/hbase/Leases.java
  Have leases created, renewed and cancelled using longs rather than
  Text. Makes for large savings in object creation.
  Javadoc edit. Changed leases Map from TreeMap to HashMap.
  (getLeaseId, createLeaseId): Renamed.
  (LeaseName, creatLeaseName, getLeaseName): Added.
* src/contrib/hbase/src/java/org/apache/hadoop/hbase/HStoreKey.java
  Added override so can extractFamily with colon appended.
  Redid extraction so we used Text#find rather than String.indexOf
  Makes for object creations savings.
* src/contrib/hbase/src/java/org/apache/hadoop/hbase/HRegionServer.java
  Pass scannerId long instead of ScannerName creating, cancelling, etc.,
  leases for scanners.
* src/contrib/hbase/src/java/org/apache/hadoop/hbase/HLog.java
* src/contrib/hbase/src/java/org/apache/hadoop/hbase/HMaster.java
  Use server name hashCode for lease naming.
* src/contrib/hbase/src/java/org/apache/hadoop/hbase/HRegion.java
  servers, rowsToLocks, locksToRows, stores do not need to be
  TreeMaps (They are more expensive than hashmaps).
* src/contrib/hbase/src/java/org/apache/hadoop/hbase/HLogKey.java
    Added Comment.
* src/contrib/hbase/src/test/org/apache/hadoop/hbase/TestGet.java
    Add in some assertions about what the expected name of the server
    is meant to be when we read HRegion.
* src/contrib/hbase/src/test/org/apache/hadoop/hbase/TestHBaseCluster.java
    (testHBaseCluster): Remove catching of exceptions. Just let them out.
* src/contrib/hbase/src/java/org/apache/hadoop/hbase/HStoreFile.java
    (doReconstructionLog): Move bunch of constructor into its own method.
* src/contrib/hbase/src/java/org/apache/hadoop/hbase/HConstants.java
    Added ImmutableBytesWriable defines for DELETE_BYTES and COPMLETE_CACHEFLUSH
* src/contrib/hbase/src/java/org/apache/hadoop/hbase/HRegionInterface.java
* src/contrib/hbase/src/java/org/apache/hadoop/hbase/HMasterRegionInterface.java
* src/contrib/hbase/src/java/org/apache/hadoop/hbase/HServerAddress.java
    Added intValue to extract port from Integer.
* src/contrib/hbase/src/java/org/apache/hadoop/hbase/io/ImmutableBytesWritable.java

> Use primitives -- long, byte [] -- in place of Long, BytesWritable, etc.
> ------------------------------------------------------------------------
>                 Key: HADOOP-1498
>                 URL: https://issues.apache.org/jira/browse/HADOOP-1498
>             Project: Hadoop
>          Issue Type: Improvement
>          Components: contrib/hbase
>            Reporter: stack
>            Assignee: stack
>            Priority: Minor
>         Attachments: primitives.patch
> Profiling, bulk of allocations are short-lived object wrapping of primitives. Examples
> + HADOOP-1483 'Use long primitives creating, renewing, and cancelling leases' now subsumed
by this issue.
> + Published APIs for region server, master and clients return ByteWritables or arrays
of ByteWritables when could be returning byte [] or byte [][].

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message