Logging of length of data received
Decreased buffer size to one page (4096)

The code is waiting for one buffer to completely fill. i.e., 16384 bytes to come before moving on.