Make sure all content is read before closing the connection in order to reuse the connection