File tree 1 file changed +3
-4
lines changed
spring-boot-project/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/batch 1 file changed +3
-4
lines changed Original file line number Diff line number Diff line change 26
26
import org .springframework .batch .core .launch .JobLauncher ;
27
27
import org .springframework .batch .core .repository .ExecutionContextSerializer ;
28
28
import org .springframework .batch .core .repository .JobRepository ;
29
- import org .springframework .batch .core .repository .dao .DefaultExecutionContextSerializer ;
30
29
import org .springframework .beans .factory .ObjectProvider ;
31
30
import org .springframework .boot .ExitCodeGenerator ;
32
31
import org .springframework .boot .autoconfigure .AutoConfiguration ;
@@ -118,8 +117,7 @@ static class SpringBootBatchConfiguration extends DefaultBatchConfiguration {
118
117
this .transactionManager = batchTransactionManager .getIfAvailable (() -> transactionManager );
119
118
this .properties = properties ;
120
119
this .batchConversionServiceCustomizers = batchConversionServiceCustomizers .orderedStream ().toList ();
121
- this .executionContextSerializer = executionContextSerializer
122
- .getIfAvailable (DefaultExecutionContextSerializer ::new );
120
+ this .executionContextSerializer = executionContextSerializer .getIfAvailable ();
123
121
}
124
122
125
123
@ Override
@@ -155,7 +153,8 @@ protected ConfigurableConversionService getConversionService() {
155
153
156
154
@ Override
157
155
protected ExecutionContextSerializer getExecutionContextSerializer () {
158
- return this .executionContextSerializer ;
156
+ return (this .executionContextSerializer != null ) ? this .executionContextSerializer
157
+ : super .getExecutionContextSerializer ();
159
158
}
160
159
161
160
}
You can’t perform that action at this time.
0 commit comments