Class DefaultBatchConfigurer
- java.lang.Object
- org.springframework.batch.core.configuration.annotation.DefaultBatchConfigurer
- All Implemented Interfaces:
BatchConfigurer
@Component public class DefaultBatchConfigurer extends java.lang.Object implements BatchConfigurer
Constructor Summary
Constructors Modifier Constructor Description protected
DefaultBatchConfigurer()
DefaultBatchConfigurer(javax.sql.DataSource dataSource)
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected JobExplorer
createJobExplorer()
protected JobLauncher
createJobLauncher()
protected JobRepository
createJobRepository()
JobExplorer
getJobExplorer()
JobLauncher
getJobLauncher()
JobRepository
getJobRepository()
org.springframework.transaction.PlatformTransactionManager
getTransactionManager()
void
initialize()
void
setDataSource(javax.sql.DataSource dataSource)
Sets the dataSource.
Method Detail
setDataSource
@Autowired(required=false) public void setDataSource(javax.sql.DataSource dataSource)
Sets the dataSource. If theDataSource
has been set once, all future values are passed are ignored (to prevent @Autowired from overwriting the value).- Parameters:
dataSource
-
getJobRepository
public JobRepository getJobRepository()
- Specified by:
getJobRepository
in interfaceBatchConfigurer
getTransactionManager
public org.springframework.transaction.PlatformTransactionManager getTransactionManager()
- Specified by:
getTransactionManager
in interfaceBatchConfigurer
getJobLauncher
public JobLauncher getJobLauncher()
- Specified by:
getJobLauncher
in interfaceBatchConfigurer
getJobExplorer
public JobExplorer getJobExplorer()
- Specified by:
getJobExplorer
in interfaceBatchConfigurer
initialize
@PostConstruct public void initialize()
createJobLauncher
protected JobLauncher createJobLauncher() throws java.lang.Exception
- Throws:
java.lang.Exception
createJobRepository
protected JobRepository createJobRepository() throws java.lang.Exception
- Throws:
java.lang.Exception
createJobExplorer
protected JobExplorer createJobExplorer() throws java.lang.Exception
- Throws:
java.lang.Exception