while(true){
if(fetchLine(receiver, outputStream) == -1){
break;
}
}
outputStream.flushCopy();
getMonitor().increaseSuccessLine(sucLineCounter);
getMonitor().increaseFailedLines(failedLineCounter);
} catch (Exception e) {
logger.error(writerID + ": write to greenplum failed.");
throw throwException(e);