Class ModularBatchConfiguration
java.lang.Object
org.springframework.batch.core.configuration.annotation.AbstractBatchConfiguration
org.springframework.batch.core.configuration.annotation.ModularBatchConfiguration
- All Implemented Interfaces:
org.springframework.beans.factory.Aware
,org.springframework.beans.factory.InitializingBean
,org.springframework.context.annotation.ImportAware
@Configuration(proxyBeanMethods=false)
public class ModularBatchConfiguration
extends AbstractBatchConfiguration
Base
Configuration
class providing common structure for enabling and using Spring Batch. Customization is
available by implementing the BatchConfigurer
interface.- Since:
- 2.2
- Author:
- Dave Syer, Mahmoud Ben Hassine
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionEstablish theJobExplorer
for the batch execution.Establish theJobLauncher
for the batch execution.Creates aAutomaticJobRegistrar
bean.Establish theJobRepository
for the batch execution.org.springframework.transaction.PlatformTransactionManager
Establish thePlatformTransactionManager
for the batch execution.Methods inherited from class org.springframework.batch.core.configuration.annotation.AbstractBatchConfiguration
afterPropertiesSet, getConfigurer, jobBuilders, jobRegistry, setImportMetadata, stepBuilders
-
Constructor Details
-
ModularBatchConfiguration
public ModularBatchConfiguration()
-
-
Method Details
-
jobRepository
Description copied from class:AbstractBatchConfiguration
Establish theJobRepository
for the batch execution.- Specified by:
jobRepository
in classAbstractBatchConfiguration
- Returns:
- The instance of the
JobRepository
. - Throws:
Exception
- TheException
thrown if error occurs.
-
jobLauncher
Description copied from class:AbstractBatchConfiguration
Establish theJobLauncher
for the batch execution.- Specified by:
jobLauncher
in classAbstractBatchConfiguration
- Returns:
- The instance of the
JobLauncher
. - Throws:
Exception
- TheException
thrown if error occurs.
-
transactionManager
public org.springframework.transaction.PlatformTransactionManager transactionManager() throws ExceptionDescription copied from class:AbstractBatchConfiguration
Establish thePlatformTransactionManager
for the batch execution.- Specified by:
transactionManager
in classAbstractBatchConfiguration
- Returns:
- The instance of the
PlatformTransactionManager
. - Throws:
Exception
- TheException
thrown if error occurs.
-
jobExplorer
Description copied from class:AbstractBatchConfiguration
Establish theJobExplorer
for the batch execution.- Specified by:
jobExplorer
in classAbstractBatchConfiguration
- Returns:
- The instance of the
JobExplorer
. - Throws:
Exception
- TheException
thrown if error occurs.
-
jobRegistrar
Creates aAutomaticJobRegistrar
bean.- Returns:
- New instance of
AutomaticJobRegistrar
. - Throws:
Exception
- TheException
thrown if an error occurs.
-