diff --git a/spring-batch-core/src/main/java/org/springframework/batch/core/domain/JobInstance.java b/spring-batch-core/src/main/java/org/springframework/batch/core/domain/JobInstance.java index 21fdc066b..e150f98f9 100644 --- a/spring-batch-core/src/main/java/org/springframework/batch/core/domain/JobInstance.java +++ b/spring-batch-core/src/main/java/org/springframework/batch/core/domain/JobInstance.java @@ -37,7 +37,6 @@ public class JobInstance extends Entity { private Job job; - // TODO declare transient or make the class serializable private BatchStatus status; private int jobExecutionCount; diff --git a/spring-batch-core/src/main/java/org/springframework/batch/core/domain/StepInstance.java b/spring-batch-core/src/main/java/org/springframework/batch/core/domain/StepInstance.java index cb5a951f1..60bc70980 100644 --- a/spring-batch-core/src/main/java/org/springframework/batch/core/domain/StepInstance.java +++ b/spring-batch-core/src/main/java/org/springframework/batch/core/domain/StepInstance.java @@ -50,7 +50,6 @@ public class StepInstance extends Entity { private JobInstance jobInstance; - // TODO declare transient or make serializable private BatchStatus status; private RestartData restartData = new GenericRestartData(new Properties()); diff --git a/spring-batch-execution/src/main/java/org/springframework/batch/execution/resource/BatchResourceFactoryBean.java b/spring-batch-execution/src/main/java/org/springframework/batch/execution/resource/BatchResourceFactoryBean.java index 48a8f4e10..f148b8b2c 100644 --- a/spring-batch-execution/src/main/java/org/springframework/batch/execution/resource/BatchResourceFactoryBean.java +++ b/spring-batch-execution/src/main/java/org/springframework/batch/execution/resource/BatchResourceFactoryBean.java @@ -155,8 +155,6 @@ public class BatchResourceFactoryBean extends AbstractFactoryBean implements String fileName = filePattern; - // TODO consider refactoring to void replacePattern() method and - // collecting variable fileName fileName = replacePattern(fileName, BATCH_ROOT_PATTERN, rootDirectory); fileName = replacePattern(fileName, JOB_NAME_PATTERN, jobName == null ? "job" : jobName); diff --git a/spring-batch-infrastructure/src/main/java/org/springframework/batch/retry/policy/ItemReaderRetryPolicy.java b/spring-batch-infrastructure/src/main/java/org/springframework/batch/retry/policy/ItemReaderRetryPolicy.java index 97489cdab..2c0a7cfb9 100644 --- a/spring-batch-infrastructure/src/main/java/org/springframework/batch/retry/policy/ItemReaderRetryPolicy.java +++ b/spring-batch-infrastructure/src/main/java/org/springframework/batch/retry/policy/ItemReaderRetryPolicy.java @@ -205,14 +205,10 @@ public class ItemReaderRetryPolicy extends AbstractStatefulRetryPolicy { boolean success = recoverer.recover(item, context .getLastThrowable()); if (!success) { - // TODO if context was null, there would be exception while - // getting success value - String count = context != null ? "" - + context.getRetryCount() : "unknown"; + int count = context.getRetryCount(); logger.error( "Could not recover from error after retry exhausted after [" - + count + "] attempts.", context - .getLastThrowable()); + + count + "] attempts.", context.getLastThrowable()); } } return item;