hbase-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Manu Kranth Chary <manukran...@gmail.com>
Subject What is the necessity of having a private ThreadLocal in FSReaderV2
Date Fri, 12 Apr 2013 23:17:43 GMT
I was trying to investigate the scenarios in which we perform a seek back
of 24 bytes(Header size) while we do a HFileBlock read. In the process I
stumbled upon this issue. In order to avoid the seek back problem, what we
do is to store the header of the next block in a class named
PrefetchedHeader. This prefetched header is stored as a private ThreadLocal
object in the FSReaderV2 class. I was wondering why we would be needing a
ThreadLocalc when each FSReader object has its own PrefetchedHeader object
and moreover if its private. Can anybody familiar with this part of the
code tell me what was the design decision that was taken at that time?

Thanks,
Manukranth Kolloju

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