Home | About | Sematext search-lucene.com search-hadoop.com
NEW: Monitor These Apps!
elasticsearch, apache solr, apache hbase, hadoop, redis, casssandra, amazon cloudwatch, mysql, memcached, apache kafka, apache zookeeper, apache storm, ubuntu, centOS, red hat, debian, puppet labs, java, senseiDB
 Search Hadoop and all its subprojects:

Switch to Plain View
HDFS >> mail # dev >> BlockInfo::triplets


+
André Oriani 2010-07-15, 16:20
Copy link to this message
-
Re: BlockInfo::triplets
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" <[EMAIL PROTECTED]> wrote:

Hi,

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

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 ?
Thanks,
André

NEW: Monitor These Apps!
elasticsearch, apache solr, apache hbase, hadoop, redis, casssandra, amazon cloudwatch, mysql, memcached, apache kafka, apache zookeeper, apache storm, ubuntu, centOS, red hat, debian, puppet labs, java, senseiDB