hadoop-hdfs-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Suresh Srinivas <sures...@yahoo-inc.com>
Subject Re: BlockInfo::triplets
Date Thu, 15 Jul 2010 20:57:49 GMT
triplets[i%3] is used to store the reference of datanode where the block replica is stored.

The datanode maintains a link list of blocks. The next two object entries are used for storing
the next and previous block references of link list for that datanode. This organization is
done to reduce the memory used for storing the link list.

On 7/15/10 9:20 AM, "André Oriani" <ra078686@students.ic.unicamp.br> wrote:


I am studying how block reports are processed, but I am not sure if I
understood how BlockInfo::triplets are used by DatanodeDescriptors and

That's what I understood:

For each Block, triplets[i] with i%3==0, gives the datanodes that are
storing the block. New datanodes are inserted in the end of array.

triplests[i+1] and triplets[i+2] are respectively the previous and next
blocks of the current one in the linked list of blocks held by datanode
triplets[i]. DatanodeDescriptor::blockList is actually is the head node of
the list.

Is it correct ?


  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message