}
mOutputBlockWriterDatasetMetadata = getOutput(OUTPUT_METADATA);
if(mOutputBlockWriterDatasetMetadata!=null)
{
XCDataset xcorr = new XCDataset();
xcorr.setXcorrelationId(dsx.getDatasetId());
xcorr.setCreationDate(dsx.getCreationDate());
xcorr.setInputTrace1(ds1.getTraceList().get(0));
xcorr.setInputTrace2(ds2.getTraceList().get(0));
xcorr.setInstanceId(dsx.getInstanceId());
xcorr.setParameters(dsx.getParameters());
xcorr.setRequestId(dsx.getRequestId());
xcorr.setUri(dsx.getUri());
JSONSerializer serializer = new JSONSerializer();
mOutputBlockWriterDatasetMetadata.write(URLEncoder.encode(serializer.include("inputTrace1").include("inputTrace2").serialize(xcorr),"UTF-8"));
}