throws IOException,
InterruptedException {
try {
// TODO expose GeoWave's AccumuloOptions
final AccumuloOperations accumuloOperations = getAccumuloOperations(context);
final AdapterStore accumuloAdapterStore = new AccumuloAdapterStore(
accumuloOperations);
final DataAdapter<?>[] adapters = JobContextAdapterStore.getDataAdapters(context);
for (final DataAdapter<?> a : adapters) {
if (!accumuloAdapterStore.adapterExists(a.getAdapterId())) {
accumuloAdapterStore.addAdapter(a);
}
}
final IndexStore accumuloIndexStore = new AccumuloIndexStore(
accumuloOperations);
final Index[] indices = JobContextIndexStore.getIndices(context);
for (final Index i : indices) {
if (!accumuloIndexStore.indexExists(i.getId())) {
accumuloIndexStore.addIndex(i);
}
}
final AdapterStore jobContextAdapterStore = getDataAdapterStore(
context,
accumuloOperations);
final IndexStore jobContextIndexStore = getIndexStore(
context,
accumuloOperations);