From 81652cc6a1af95c539a1502ac01f080b6845a81e Mon Sep 17 00:00:00 2001 From: lucasward Date: Wed, 28 Jan 2009 20:12:42 +0000 Subject: [PATCH] BATCH-1007: Job and Step now have consistent attribute names for referencing the job repository, they're both 'job-repository' now. The docs have been updated accordingly. --- .../batch/core/configuration/xml/JobParser.java | 5 +---- .../batch/core/configuration/xml/spring-batch-2.0.xsd | 10 +--------- .../xml/JobExecutionListenerParserTests-context.xml | 2 +- .../xml/RepositoryJobParserTests-context.xml | 2 +- 4 files changed, 4 insertions(+), 15 deletions(-) diff --git a/spring-batch-core/src/main/java/org/springframework/batch/core/configuration/xml/JobParser.java b/spring-batch-core/src/main/java/org/springframework/batch/core/configuration/xml/JobParser.java index 00281206e..a1ed84954 100644 --- a/spring-batch-core/src/main/java/org/springframework/batch/core/configuration/xml/JobParser.java +++ b/spring-batch-core/src/main/java/org/springframework/batch/core/configuration/xml/JobParser.java @@ -49,10 +49,7 @@ public class JobParser extends AbstractBeanDefinitionParser { String jobName = element.getAttribute("id"); builder.addConstructorArgValue(jobName); - String repositoryAttribute = element.getAttribute("repository"); - if (!StringUtils.hasText(repositoryAttribute)) { - repositoryAttribute = "jobRepository"; - } + String repositoryAttribute = element.getAttribute("job-repository"); builder.addPropertyReference("jobRepository", repositoryAttribute); String restartableAttribute = element.getAttribute("restartable"); diff --git a/spring-batch-core/src/main/resources/org/springframework/batch/core/configuration/xml/spring-batch-2.0.xsd b/spring-batch-core/src/main/resources/org/springframework/batch/core/configuration/xml/spring-batch-2.0.xsd index c5a3636d8..fd0940372 100644 --- a/spring-batch-core/src/main/resources/org/springframework/batch/core/configuration/xml/spring-batch-2.0.xsd +++ b/spring-batch-core/src/main/resources/org/springframework/batch/core/configuration/xml/spring-batch-2.0.xsd @@ -30,15 +30,7 @@ - - - - - - + diff --git a/spring-batch-core/src/test/resources/org/springframework/batch/core/configuration/xml/JobExecutionListenerParserTests-context.xml b/spring-batch-core/src/test/resources/org/springframework/batch/core/configuration/xml/JobExecutionListenerParserTests-context.xml index 05fa05e7d..005494f21 100644 --- a/spring-batch-core/src/test/resources/org/springframework/batch/core/configuration/xml/JobExecutionListenerParserTests-context.xml +++ b/spring-batch-core/src/test/resources/org/springframework/batch/core/configuration/xml/JobExecutionListenerParserTests-context.xml @@ -6,7 +6,7 @@ - + diff --git a/spring-batch-core/src/test/resources/org/springframework/batch/core/configuration/xml/RepositoryJobParserTests-context.xml b/spring-batch-core/src/test/resources/org/springframework/batch/core/configuration/xml/RepositoryJobParserTests-context.xml index 4f6c32479..089465c13 100644 --- a/spring-batch-core/src/test/resources/org/springframework/batch/core/configuration/xml/RepositoryJobParserTests-context.xml +++ b/spring-batch-core/src/test/resources/org/springframework/batch/core/configuration/xml/RepositoryJobParserTests-context.xml @@ -20,7 +20,7 @@ - +