From 63eee035d464f057e85e6a69f712fad387d76ee4 Mon Sep 17 00:00:00 2001 From: Dave Syer Date: Sun, 20 Mar 2011 08:59:25 +0000 Subject: [PATCH] Correction for ChunkListener docs --- src/site/docbook/reference/step.xml | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/src/site/docbook/reference/step.xml b/src/site/docbook/reference/step.xml index a1d1b91e6..4d4ecbadf 100644 --- a/src/site/docbook/reference/step.xml +++ b/src/site/docbook/reference/step.xml @@ -745,9 +745,9 @@ itemWriter.write(items); A chunk is defined as the items processed within the scope of a transaction. Committing a transaction, at each commit interval, - commits a 'chunk'. A ChunkListener may be + commits a 'chunk'. A ChunkListener can be useful to perform logic before a chunk begins processing or after a - chunk has completed: + chunk has completed successfully: public interface ChunkListener extends StepListener { @@ -760,10 +760,8 @@ itemWriter.write(items); The beforeChunk method is called after the transaction is started, but before read is called on the ItemReader. Conversely, - afterChunk is called after the last call to - write on the - ItemWriter, but before the chunk has been - committed. + afterChunk is called after the chunk has been + committed (and not at all if there is a rollback). The annotations corresponding to this interface are: