ignore onAllDataRead and use input.isFinished() as completion signal