diff --git a/docs/src/site/docbook/reference/retry.xml b/docs/src/site/docbook/reference/retry.xml
index ac6bbd22d..644b997df 100644
--- a/docs/src/site/docbook/reference/retry.xml
+++ b/docs/src/site/docbook/reference/retry.xml
@@ -131,8 +131,7 @@ Object result = template.execute(new RetryCallback() {
RetryOperations.execute() method and potentially losing the
context that was on the stack. To avoid losing it we have to introduce a
storage strategy to lift it off the stack and put it (at a minimum) in
- heap storage. For this purpose Spring Batch provides the
- ItemReaderRetryPolicy and a storage strategy
+ heap storage. For this purpose Spring Batch provides a storage strategy
RetryContextCache. The default implementation of
the RetryContextCache is in memory, using a
simple Map. Advanced usage with multiple
@@ -147,10 +146,9 @@ Object result = template.execute(new RetryCallback() {
Part of the reponsibility of a stateful retry policy is to
recognise the failed operations when they come back in a new
transaction. To facilitate this in the commonest case where an object
- of some type (like a message or message payload) is being processed,
- Spring Batch provides the
- ItemReaderRetryPolicy. This works in
- conjunction with a special RetryCallback
+ (like a message or message payload) is being processed, Spring Batch
+ provides the ItemReaderRetryPolicy. This works
+ in conjunction with a special RetryCallback
implementation ItemReaderRetryCallback, which
in turn relies on the user providing an
ItemReader and an
@@ -159,13 +157,17 @@ Object result = template.execute(new RetryCallback() {
writer.
The way the failed operations are recognised in this
- implementation is by recognising the object that is returned from the
- ItemReader. To recognise the item the user can
- provide an ItemKeyGenerator strategy, either by
+ implementation is by identifying the object that is returned from the
+ ItemReader. To identify the item the user can
+ provide an ItemKeyGenerator strategy, and this
+ is responsible for returning a unique key identifying the item. The
+ identifier is used as a key in the
+ RetryContextCache. An
+ ItemKeyGenerator can be provided either by
injecting it directly into the
ItemReaderRetryCallback, or by implementing the
interface in the ItemReader, or by accepting
- the default which is to simply use the item to identify itself.
+ the default which is to simply use the item itself as a key.
When the retry is exhausted, because a stateful retry is always
in a fresh transaction, there is also the option to handle the failed
@@ -258,7 +260,7 @@ Object result = template.execute(new RetryCallback() {
The RetryOperationsInterceptor executes the
intercepted method and retries on failure according to the
RetryPolicy in the provided
- RepeatTemplate.
+ RepeatTemplate.
Here is an example of declarative iteration using the Spring AOP
namespace to repeat a service call to a method called