When using the `AsyncItemProcessor` and `AsyncItemWriter`, business
exceptions that occur during the process phase are hidden by an
`ExecutionException` that is returned wrapping the originally thrown
exception in the `AsyncItemWriter`. In this commit, we now unwrap any
`ExecutionException` that is returned and throw the cause. Debug
logging is also added to allow the logging of the original exception as
well.
Resolves BATCH-2386
When using the `MessageChannelPartitionHandler`, the reply channel is an
instance variable. However, when the handle method is called, if a
reply channel is not injected, it will create a new one. If multiple
jobs recycle the same instance of the partition handler, you may end up
having messages crossed/lost. This PR removes the creation of the reply
channel for each call to the handle method and documents that this
comonent should be step scoped.
Resolves BATCH-2288
The new Spring 5 baseline consists of Spring 5, Hibernate 5, and Java 8.
This commit addresses any changes to create a successful build of Spring
Batch under those guidances. Further commits will be coming to address
Java 8 specifics as areas of the project are touched.
Resolves BATCH-2536
Hibernate 5 changed the signature of the Session#close() method from
returning a Connection to being void. To support both verions, we've
moved to making the call via reflection.
This commit also upgrades the ActiveMQ version used in testing to be
compliant with the Spring IO Platform.
Resolves BATCH-2496
Spring Integration 4.2 has fixed a bug where integration components
were being started too early. SmokeTests was relying on this bug to
start the test class which is also a @MessageEndpoint.
This commit updates the test to use a nested inner-class for the
endpoint and a bean declaration in the XML configuration. This allows
the test to pass against both Spring Integration 4.0 and 4.2.
In various places in the code base a debug message is constructed
unconditionally. This adds unnecessary overhead in the common case when
debug logging is off.
- add guards around debug statements in non-test code
Issue: BATCH-2412
This commit adds the feature of allowing a delegate ItemWriter to be an
ItemStreamWriter and have Spring Batch respect the ItemStream lifecycle
events without explicitly configuring the delegate as a stream.
When using remote partitioning, each slave worker persists it's current
status in the same job repsository that the master uses. Because of
this, there is no hard need for the master to wait for each worker to
send a formal response once it's work is complete. Instead, the master
(at the cost of polling a db periodically) can determine if the workers
are done by looking up each partition's status in the job repository.
This commit removes the requirement for a reply channel and implements
the polling of the job repository to determine if the workers are done.
BATCH-2332
The AsyncItemWriter is used in conjunction with the AsyncItemProcessor
to unwrap the Futures that are returned by that processor.
Traditionally when an ItemProcessor returns null, it's considered having
been filtered out and should not be passed to the ItemWriter. In this
case, the AsyncItemWriter was not checking for nulls so they were being
passed to the delegate ItemWriter. Most of the OOTB ItemWriters do not
perform a null check prior to doing the write so they were throwing NPEs
when using this paradigm.
* Use Gradle 1.11
* Remove SpringSource references
* Update JavaDoc overview
* Update Jacoco conf + Add license/manifest files
* Addresses also BATCH-2187
* Update a number of unit tests to not be ignored
Jira: https://jira.springsource.org/browse/BATCH-2144
* Removed APT files
* General formatting and spelling fixes
* Converted README.md to docbook
* Expanded converted README.md docs to include usable code snippets
* What's new
* JSR-352
* Convert Spring Batch Integration apt files into docbook and use as chapter
* Remove site dir from Spring Batch Integration where converted apt files used
to live
Also changes for deprecation of interval-trigger on poller.
BATCHADM-125 Polishing (garyrussell)
Revert spaces to tabs; fix up some inconsistent newlines.
RemoteChunkFaultTolerantStepJdbcIntegrationTests-context.xml
FileDropJobIntegrationTests-context.xml
AbstractIntegrationViewTests-context.xml
VanillaIntegrationTests-context.xml
RepeatTransactionalPollingIntegrationTests-context.xml
RetryRepeatTransactionalPollingIntegrationTests-context.xml
TransactionalPollingIntegrationTests-context.xml
RetryTransactionalPollingIntegrationTests-context.xml
- add sequence info to chunks
- Improve logging in ChunkMessageChannelItemWriter
- Add mysql/h2/derby properties to integration project
- Add drop scripts necessary for persistent databases