-
Notifications
You must be signed in to change notification settings - Fork 2.5k
Description
Bug description
With this change, a steps context is no longer persisted inside SimpleStepExecutionSplitter.java, causing the execution context created by a partitioner to be lost, preventing a remote worker from loading the created context. Specifically the call to jobRepository.addAll prior to batch 6 ensured the context was persisted
Specifically, after the contexts are created, MessageChannelPartitionHandler.doHandle is responsible to create and send the message, when the remote worker receives the message, it loads the steps through the job repository.
Environment
Spring boot 4.0.0, batch 6.0.0, batch-integration 6.0.0, JDK21
Steps to reproduce
(can be run with ./gradlew run) Specifically note line 91 which should get the context from the partitioner on line 197
This bug is seen with a partitioned step using message channels for delivery and a persistence layer for the jobRepository.
Expected behavior
The partitioner should initialize the step contexts on the controller and update the step in the repository. This enabling the worker to load the step from the repository and use the context created earlier