title: Why Hadoop API FSDataInputStream read less than buffer size?
body: <p>I have a binary file on hadoop distributed file system that i want to read . I am using FSDataInputStream ( which extends DataInputStream ) . I have buffer of length "len" . I use readBytes = stream.read(buffer) method to read "len" number of bytes from file into buffer. 
  BUT Actual number of bytes read ( readBytes ) are less than buffer size ( len ), even though I know that there are "len" number of bytes present in file. 
  So why does FSDataInputStream read less number of bytes than i ask it to read? Any IDEA?</p>