diff --git a/spring-batch-core/src/main/java/org/springframework/batch/core/configuration/xml/JobRepositoryParser.java b/spring-batch-core/src/main/java/org/springframework/batch/core/configuration/xml/JobRepositoryParser.java
index 62aa245b7..7573c6283 100644
--- a/spring-batch-core/src/main/java/org/springframework/batch/core/configuration/xml/JobRepositoryParser.java
+++ b/spring-batch-core/src/main/java/org/springframework/batch/core/configuration/xml/JobRepositoryParser.java
@@ -15,12 +15,11 @@
*/
package org.springframework.batch.core.configuration.xml;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
import org.springframework.beans.factory.config.BeanDefinition;
import org.springframework.beans.factory.config.RuntimeBeanReference;
import org.springframework.beans.factory.support.BeanDefinitionBuilder;
import org.springframework.beans.factory.xml.AbstractSingleBeanDefinitionParser;
+import org.springframework.util.StringUtils;
import org.w3c.dom.Element;
/**
@@ -33,8 +32,6 @@ import org.w3c.dom.Element;
*/
public class JobRepositoryParser extends AbstractSingleBeanDefinitionParser {
- private final Log logger = LogFactory.getLog(getClass());
-
protected String getBeanClassName(Element element) {
return "org.springframework.batch.core.repository.support.JobRepositoryFactoryBean";
}
@@ -49,15 +46,20 @@ public class JobRepositoryParser extends AbstractSingleBeanDefinitionParser {
String transactionManager = element.getAttribute("transaction-manager");
- if (logger.isDebugEnabled()) {
- logger.debug("Using data-source: " + dataSource);
- logger.debug("Using transaction-manager: " + transactionManager);
- }
-
+ String isolationLevelForCreate = element.getAttribute("isolation-level-for-create");
+
+ String tablePrefix = element.getAttribute("table-prefix");
+
RuntimeBeanReference ds = new RuntimeBeanReference(dataSource);
builder.addPropertyValue("dataSource", ds);
RuntimeBeanReference tx = new RuntimeBeanReference(transactionManager);
builder.addPropertyValue("transactionManager", tx);
+ if (StringUtils.hasText(isolationLevelForCreate)) {
+ builder.addPropertyValue("isolationLevelForCreate", isolationLevelForCreate);
+ }
+ if (StringUtils.hasText(tablePrefix)) {
+ builder.addPropertyValue("tablePrefix", tablePrefix);
+ }
builder.setRole(BeanDefinition.ROLE_SUPPORT);
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 686a42a5f..3c1e88ef7 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
@@ -188,7 +188,7 @@ The decider is a reference to a JobExecutionDecider that can produce a status to
-
+
+
+
+
+
+
+
+
+
+
diff --git a/spring-batch-core/src/test/resources/org/springframework/batch/core/configuration/xml/JobRepositoryParserTests-context.xml b/spring-batch-core/src/test/resources/org/springframework/batch/core/configuration/xml/JobRepositoryParserTests-context.xml
index 33a907cce..3de5e8421 100644
--- a/spring-batch-core/src/test/resources/org/springframework/batch/core/configuration/xml/JobRepositoryParserTests-context.xml
+++ b/spring-batch-core/src/test/resources/org/springframework/batch/core/configuration/xml/JobRepositoryParserTests-context.xml
@@ -12,6 +12,6 @@
-
+
\ No newline at end of file