hadoopcompatiblity: Exception handling in outputcollector and some cleaning up.