Class BasicBatchConfigurer
- java.lang.Object
- org.springframework.boot.autoconfigure.batch.BasicBatchConfigurer
- All Implemented Interfaces:
org.springframework.batch.core.configuration.annotation.BatchConfigurer
- Direct Known Subclasses:
JpaBatchConfigurer
public class BasicBatchConfigurer extends Object implements org.springframework.batch.core.configuration.annotation.BatchConfigurer
BasicBatchConfigurer
implementation.
Constructor Summary
Constructors Modifier Constructor Description protected
BasicBatchConfigurer(BatchProperties properties, DataSource dataSource, TransactionManagerCustomizers transactionManagerCustomizers)
Create a newBasicBatchConfigurer
instance.
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected org.springframework.batch.core.explore.JobExplorer
createJobExplorer()
protected org.springframework.batch.core.launch.JobLauncher
createJobLauncher()
protected org.springframework.batch.core.repository.JobRepository
createJobRepository()
protected org.springframework.transaction.PlatformTransactionManager
createTransactionManager()
protected String
determineIsolationLevel()
Determine the isolation level for create* operation of theJobRepository
.org.springframework.batch.core.explore.JobExplorer
getJobExplorer()
org.springframework.batch.core.launch.JobLauncher
getJobLauncher()
org.springframework.batch.core.repository.JobRepository
getJobRepository()
org.springframework.transaction.PlatformTransactionManager
getTransactionManager()
void
initialize()
Constructor Detail
BasicBatchConfigurer
protected BasicBatchConfigurer(BatchProperties properties, DataSource dataSource, TransactionManagerCustomizers transactionManagerCustomizers)
Create a newBasicBatchConfigurer
instance.- Parameters:
properties
- the batch propertiesdataSource
- the underlying data sourcetransactionManagerCustomizers
- transaction manager customizers (ornull
)
Method Detail
getJobRepository
public org.springframework.batch.core.repository.JobRepository getJobRepository()
- Specified by:
getJobRepository
in interfaceorg.springframework.batch.core.configuration.annotation.BatchConfigurer
getTransactionManager
public org.springframework.transaction.PlatformTransactionManager getTransactionManager()
- Specified by:
getTransactionManager
in interfaceorg.springframework.batch.core.configuration.annotation.BatchConfigurer
getJobLauncher
public org.springframework.batch.core.launch.JobLauncher getJobLauncher()
- Specified by:
getJobLauncher
in interfaceorg.springframework.batch.core.configuration.annotation.BatchConfigurer
getJobExplorer
public org.springframework.batch.core.explore.JobExplorer getJobExplorer() throws Exception
- Specified by:
getJobExplorer
in interfaceorg.springframework.batch.core.configuration.annotation.BatchConfigurer
- Throws:
Exception
initialize
@PostConstruct public void initialize()
createJobExplorer
protected org.springframework.batch.core.explore.JobExplorer createJobExplorer() throws Exception
- Throws:
Exception
createJobLauncher
protected org.springframework.batch.core.launch.JobLauncher createJobLauncher() throws Exception
- Throws:
Exception
createJobRepository
protected org.springframework.batch.core.repository.JobRepository createJobRepository() throws Exception
- Throws:
Exception
determineIsolationLevel
protected String determineIsolationLevel()
Determine the isolation level for create* operation of theJobRepository
.- Returns:
- the isolation level or
null
to use the default
createTransactionManager
protected org.springframework.transaction.PlatformTransactionManager createTransactionManager()