Hi all,
I need some info related to the code section which handles the following
operations.

Basically DataXceiver.c on the client side  transmits the block in packets
and on the data node side we have DataXceiver.c and BlockReceiver.c files
which take care of writing these packets in order to a block file until the
last packet for the block is received. I want some info around this area
where in BlockReceiver.c , i have seen a PacketResponder class and a
BlockReceiver class where in two places you are finalizing the block (What
i understood by finalizing is that when the last packet for the block is
received, you are closing the block file). In PacketResponder class in two
places you are using finalizeBlock() function, one in lastDataNodeRun()
function and the other in run() method and in BlockReceiver.c you are using
finalizeBlock() in receiveBlock() function. I understood from the comments
that the finalizeBlock() call from run() method is done for the datanode
with which client directly interacts and finalizeBlock() call from
receiveBlock() function is done for all the datanodes where the block is
sent for replication. But i didn't understand why there is a
finalizeBlock() call from lastDataNodeRun() function.
Can someone explain me about this? I may be wrong at most of the places of
my understanding of the workflow. Correct me if i am wrong.

Thanks,
Kartheek

Reply via email to