Skip to content

Commit 284b7dc

Browse files
rchandavaramfmbenhassine
authored andcommitted
Improve code example in "Configuring and Running a Job" section
The sample that shows how to provide a custom transaction manager via a BatchConfigurer has been updated to use the constructor of `DefaultBatchConfigurer` that takes a DataSource. Issue #3888
1 parent ff2bcdb commit 284b7dc

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

spring-batch-docs/asciidoc/job.adoc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -449,8 +449,8 @@ example shows how to provide a custom transaction manager:
449449
[source, java]
450450
----
451451
@Bean
452-
public BatchConfigurer batchConfigurer() {
453-
return new DefaultBatchConfigurer() {
452+
public BatchConfigurer batchConfigurer(DataSource dataSource) {
453+
return new DefaultBatchConfigurer(dataSource) {
454454
@Override
455455
public PlatformTransactionManager getTransactionManager() {
456456
return new MyTransactionManager();

0 commit comments

Comments
 (0)