BATCH-2093: Exposed DefaultBatchConfigurer#createJobLauncher for extension

This commit is contained in:
Michael Minella
2015-02-06 10:41:15 -06:00
parent 87f3852a6c
commit 4cfd5c47ea

View File

@@ -15,8 +15,12 @@
*/
package org.springframework.batch.core.configuration.annotation;
import javax.annotation.PostConstruct;
import javax.sql.DataSource;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.springframework.batch.core.configuration.BatchConfigurationException;
import org.springframework.batch.core.explore.JobExplorer;
import org.springframework.batch.core.explore.support.JobExplorerFactoryBean;
@@ -32,9 +36,6 @@ import org.springframework.jdbc.datasource.DataSourceTransactionManager;
import org.springframework.stereotype.Component;
import org.springframework.transaction.PlatformTransactionManager;
import javax.annotation.PostConstruct;
import javax.sql.DataSource;
@Component
public class DefaultBatchConfigurer implements BatchConfigurer {
private static final Log logger = LogFactory.getLog(DefaultBatchConfigurer.class);
@@ -109,7 +110,7 @@ public class DefaultBatchConfigurer implements BatchConfigurer {
}
}
private JobLauncher createJobLauncher() throws Exception {
protected JobLauncher createJobLauncher() throws Exception {
SimpleJobLauncher jobLauncher = new SimpleJobLauncher();
jobLauncher.setJobRepository(jobRepository);
jobLauncher.afterPropertiesSet();