public interface IAsynchronousWriteStatementBufferFactory<S extends org.openrdf.model.Statement> extends IStatementBufferFactory<S>
ITripleStore
.Modifier and Type | Method and Description |
---|---|
void |
awaitAll()
Close buffers and then await their
Future s. |
void |
cancelAll(boolean mayInterruptIfRunning)
Cancel all
Future s. |
void |
close()
Close the buffers.
|
CounterSet |
getCounters()
Return performance counters defined by this factory.
|
boolean |
isAnyDone()
Return
true if the Future for any of the
asynchronous write buffers is done. |
IStatementBuffer<S> |
newStatementBuffer()
Return a new
IStatementBuffer which may be used to bulk load
RDF data. |
IStatementBuffer<S> newStatementBuffer()
IStatementBuffer
which may be used to bulk load
RDF data. The writes will proceed asynchronously using buffers shared
by all IStatementBuffer
s returned by this factory for a
given instance of this class. Each IStatementBuffer
MAY be
recycled using IBuffer.reset()
or simply discarded after its
use.newStatementBuffer
in interface IStatementBufferFactory<S extends org.openrdf.model.Statement>
boolean isAnyDone()
true
if the Future
for any of the
asynchronous write buffers is done.
Note: This method should be invoked periodically to verify that no
errors have been encountered by the asynchronous write buffers. If
this method returns true
, invoke awaitAll()
,
which will detect any error(s), cancel the other Future
s,
and throw an error back to you.
void close()
void cancelAll(boolean mayInterruptIfRunning)
mayInterruptIfRunning
- void awaitAll() throws InterruptedException, ExecutionException
Future
s. Once closed, the
buffers will not accept further input and the consumers will
eventually drain the buffers and report that they are exhausted. The
Future
s will become available once the iterators are
exhausted.ExecutionException
- if any Future
fails.InterruptedException
- if interrupted while awaiting any of the Future
s.CounterSet getCounters()
Copyright © 2006–2019 SYSTAP, LLC DBA Blazegraph. All rights reserved.