[ 
https://issues.apache.org/jira/browse/HDFS-14108?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16702329#comment-16702329
 ] 

Hudson commented on HDFS-14108:
-------------------------------

SUCCESS: Integrated in Jenkins build Hadoop-trunk-Commit #15519 (See 
[https://builds.apache.org/job/Hadoop-trunk-Commit/15519/])
HDFS-14108. Performance improvement in BlockManager Data Structures. (gifuma: 
rev 4ca3a6b21a3a25acf16d026c699154047b1f686b)
* (edit) 
hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/blockmanagement/BlockManager.java


> Performance improvement in BlockManager Data Structures
> -------------------------------------------------------
>
>                 Key: HDFS-14108
>                 URL: https://issues.apache.org/jira/browse/HDFS-14108
>             Project: Hadoop HDFS
>          Issue Type: Improvement
>          Components: hdfs
>    Affects Versions: 3.2.0
>            Reporter: BELUGA BEHR
>            Assignee: BELUGA BEHR
>            Priority: Minor
>             Fix For: 3.3.0
>
>         Attachments: HDFS-14108.1.patch
>
>
> # Prefer {{ArrayList}} to {{LinkedList}} when simply adding/iterating
> # Prefer {{HashSet}} to {{TreeSet}} when no ordering is required
> # Other performance improvements
> # Check style fixes
> https://stackoverflow.com/questions/322715/when-to-use-linkedlist-over-arraylist-in-java
> {code:java}
>     final Set<Node> excludedNodes = new HashSet<>();
>     for(BlockReconstructionWork rw : reconWork){
>       // Do no bother wasting time clearing out the collection, let GC do 
> that work later
>       excludedNodes.clear();
>       // use {{addAll}} here
>       for (DatanodeDescriptor dn : rw.getContainingNodes()) {
>         excludedNodes.add(dn);
>       }
> {code}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to