RESOLVED - BATCH-996: use default retryLimit == 1 (not 0) in *StepFactoryBean

change the default value, emphasize in javadoc 
update tests to JUnit4
This commit is contained in:
robokaso
2009-01-14 13:43:10 +00:00
parent eecf8345a0
commit c18dbda106
3 changed files with 39 additions and 18 deletions

View File

@@ -48,7 +48,7 @@ public class SimpleRetryPolicy implements RetryPolicy {
*/
public final static int DEFAULT_MAX_ATTEMPTS = 3;
private volatile int maxAttempts;
private volatile int maxAttempts = 1;
private BinaryExceptionClassifier retryableClassifier = new BinaryExceptionClassifier();
@@ -66,7 +66,7 @@ public class SimpleRetryPolicy implements RetryPolicy {
* Create a {@link SimpleRetryPolicy} with the specified number of retry
* attempts, and default exceptions to retry.
*
* @param maxAttempts
* @param maxAttempts number of allowed attempts (typically >= 1)
*/
public SimpleRetryPolicy(int maxAttempts) {
super();