Package org.zalando.fahrschein
Interface BatchHandler
-
public interface BatchHandlerAllows wrappingListener.accept(List)andCursorManager.onSuccess(String, Cursor)inside one transaction, with automatic rollback if cursor commit fails. This is mainly useful when cursors are persisted in the same transactional datasource that the listener is using, for exampleJdbcCursorManager. Be careful when using this with aManagedCursorManager, as it is possible that the response from a successful commit gets lost by the network. When the actions of theListenerare now rolled back, those events won't be received again.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidprocessBatch(IORunnable continuation)
-
-
-
Method Detail
-
processBatch
void processBatch(IORunnable continuation) throws IOException
- Parameters:
continuation- A closure which will process the current batch when called.- Throws:
IOException
-
-