The documentation generation change introduced
in #4167 seems to scan more files than previously
WRT checking the code formatting style.
This commit fixes the formatting of the files
that do not conform to the Spring style.
This commit replaces the usage of List with Chunk
where appropriate. Summary of changes:
- The Chunk class was moved from the `org.springframework.batch.core.step.item` package to the `org.springframework.batch.item` package
- The signature of the method `ItemWriter#write(List)` was changed to `ItemWriter#write(Chunk)`
- All implementations of `ItemWriter` were updated to use the Chunk API instead of List
- All methods in the `ItemWriteListener` interface were updated to use the Chunk API instead of List
- All implementations of `ItemWriteListener` were updated to use the Chunk API instead of List
- The constructor of `ChunkRequest` was changed to accept a Chunk instead of a Collection of items
- The return type of `ChunkRequest#getItems()` was changed from List to Chunk
Resolves#3954
Let fluent setters of `SimpleStepBuilder` return `this` with type `SimpleStepBuilder`.
This makes the required order of some fluent setters a bit more lenient and prevents
that `AbstractTaskletStepBuilder::listener` for parameters of type `Object` is invoked
although an overloaded method specific for `SimpleStepBuilder` is intended.
Fixes#773 and #1098.
This commits changes the type of the transaction manager
from `DataSourceTransactionManager` to `JdbcTransactionManager`
in the default configuration of `@EnableBatchProcessing`.
The `JdbcTransactionManager` adds common JDBC exception translation
which is beneficial for Spring Batch to improve exception handling
and error reporting.
Resolves#4126
These tests seem to start failing since 31af573 but were
not caught due to #4121. This commit fixes the tests that
are related to infrastructure beans configuration.
Some other tests seems to have started failing as well but
are not related to this change set. There were temporarily
ignored in this commit and will be addressed separately.
Issue #4121
This is what is recommended by the observability
team in terms of tag naming with micrometer 1.10+
for consistency between both metrics and tracing.
In #4065, only some metrics have been updated to
follow this tag naming convention, but not all of
them. This commit updates all metrics in a similar
way for consistency.
Related to #4065 and #4098.
The lazy proxy creation of batch artifacts was intended to prevent
configuration cycles from happening. However, this is implemented in
SimpleBatchConfiguration but not in ModularBatchConfiguration.
Removing this laziness in the configuration process does not introduce
any regression neither in tests nor in samples. This commit makes
SimpleBatchConfiguration consistent with ModularBatchConfiguration.
Before this commit, the datasource was autowired in
AbstractBatchConfiguration. This was causing context
startup failures when no datasource or more than one
datasource is present in the context.
This commit fixes these failures by looking for the
datasource in the application context. This also
prevents cyclic configuration dependencies when
the datasource bean is defined in the same class where
other batch artifacts are autowired.
Resolves#3991
- Add field createTime for StepExecution.
- Add column create_time for batch_step_execution and make start_time default null.
- Make getLastStepExecution order by createTime instead of startTime.
- Add migration scripts for 5.0
Resolves#4049