private void writeResultsToNewAdapter() throws IOException { if (outputStore != null) { final Index[] leftIndices = getIndicesForAdapter( leftStore, leftAdapterTypeName, leftInternalAdapterStore, leftIndexStore); final FeatureDataAdapter newLeftAdapter = createOutputAdapter(leftStore, leftAdapterTypeName, leftIndices, outLeftAdapterTypeName); final Index[] rightIndices = getIndicesForAdapter( rightStore, rightAdapterTypeName, rightInternalAdapterStore, rightIndexStore); final FeatureDataAdapter newRightAdapter = createOutputAdapter( rightStore, rightAdapterTypeName, rightIndices, outRightAdapterTypeName); // Write each feature set to new adapter and store using original // indexing methods. RDDUtils.writeRDDToGeoWave(sc, leftIndices, outputStore, newLeftAdapter, getLeftResults()); RDDUtils.writeRDDToGeoWave(sc, rightIndices, outputStore, newRightAdapter, getRightResults()); } }