Message position overruns

Playing with Kafka I have seen it return packets that are not complete. I've tried to identify when this happens and return the message set without the incomplete last message