public abstract class Exporter<K,V> extends Object
Modifier and Type | Class and Description |
---|---|
static interface |
Exporter.Context |
Constructor and Description |
---|
Exporter() |
Modifier and Type | Method and Description |
---|---|
void |
init(Exporter.Context exporterContext) |
protected abstract void |
processExports(Iterator<SequencedExport<K,V>> exports)
Must be able to handle same key being exported multiple times and key being exported out of
order.
|
public void init(Exporter.Context exporterContext) throws Exception
Exception
protected abstract void processExports(Iterator<SequencedExport<K,V>> exports)
If multiple export entries with the same key are passed in, then the entries with the same key will be consecutive and in ascending sequence order.
If the call to process exports is unexpectedly terminated, it will be called again later with at least the same data. For example suppose an exporter was passed the following entries.
Assume the exporter exports some of these and then fails before completing all of them. The next time its called it will be passed what it saw before, but it could also be passed more.
Copyright © 2016 The Apache Software Foundation. All rights reserved.