Bug 206861 The data set cache should handle IOException and the cancel request from customer
The data set data will be saved into disk file in the first query and it will be loaded in the later time. The processing of write disk file may be cancelled by customer request or IOException. Using the data from the bad file will cause error.
data/org.eclipse.birt.data/src/org/eclipse/birt/data/engine/executor/cache/disk/DiskSortExport2.java
{
	private int dataCountOfUnit;
	private int dataCountOfTotal;
	private MergeTempFileUtil tempFileUtil;
	private List currRowFiles;
	
	
	private MergeSortUtil mergeSortUtil;
	
	private IResultObject[] rowBuffer = null;
	
	
	private int inMemoryPos;
	
	private IRowIterator goalRowIterator = null;
	/**
	 * @param dataProvider
	 */
	DiskSortExport2( Map infoMap, Comparator comparator,
			ResultObjectUtil resultObjectUtil )
	{
		dataCountOfUnit = Integer.parseInt( (String) infoMap.get( "dataCountOfUnit" ) );
		if ( dataCountOfUnit < 2 )
		{
			throw new IllegalArgumentException( "the dataCountOfUnit of "
					+ dataCountOfUnit + " is less than 2 "
					+ ", and then merge sort on file can not be done" );
		}
		rowBuffer = new IResultObject[dataCountOfUnit];