Commit Graph

5627 Commits

Author SHA1 Message Date
Mahmoud Ben Hassine
3fbfbb9503 Fix documentation of chunk-oriented processing
Resolves #1629 #1179 #1069 #3833
2021-03-11 06:43:19 +01:00
Niels Ferguson
63b6dea514 Fix incorrect usage of StringBuilder#append in TransactionAwareBufferedWriter
Issue #3745
2021-03-10 10:13:24 +01:00
Mahmoud Ben Hassine
a15496805b Add timeout when flushing items to Kafka in KafkaItemWriter
Issue #3773
2021-03-09 14:48:25 +01:00
Mahmoud Ben Hassine
572a302725 Refine contribution #3827
* Update year in licence headers
* Update Javadoc
* Add `this` keyword where appropriate
2021-03-09 14:07:15 +01:00
Jacob Botuck
c886a60b4d KafkaItemWriter.write should not return until items are confirmed to have been written
Issue #3773
2021-03-09 14:04:19 +01:00
siqqQ
a6f283b4a8 Change the value of the kind attribute to ref
Issue #1479
2021-03-02 17:39:07 +01:00
Mahmoud Ben Hassine
1d23d66e27 Add java.sql.Timestamp to trusted classes in Jackson serializer
Resolves #3855
2021-03-01 13:39:35 +01:00
Mahmoud Ben Hassine
602656a241 Polish contribution 58b2a7a2
* Update year in license headers
* Refactor test
2021-03-01 11:25:42 +01:00
Jagger
58b2a7a26b Add Arrays$ArrayList to trusted classes in Jackson serializer
Issue #3830
2021-03-01 11:24:19 +01:00
Mahmoud Ben Hassine
7e7d39da05 Fix typo in CONTRIBUTING.md 2021-02-25 09:32:17 +01:00
Mahmoud Ben Hassine
be1192cac2 Fix regression in docs
Master/Slave terms were replaced
with Manager/Worker in 85b3e9002
but this seems to be lost when
merging efdce562b0.
2021-02-24 15:09:06 +01:00
Mahmoud Ben Hassine
7b2d7d1993 Refine af14a2e471
* Make default constructors call other constructors with default values
* Fix formatting
* Update year in license headers
2021-02-23 15:56:51 +01:00
Marten Deinum
af14a2e471 Provide constructors for injection
Currently when reading/writing JSON and using the reader/marshaller provided
and you want a custom Gson or ObjectMapper instance it still creates the not
needed instance. Move the construction to a constructor and provide a constructor
to directly pass in the pre-configured Gson or ObjectMapper instance.

The same approach is used in Spring itself where Gson or ObjectMapper instances
can be passed in.
2021-02-23 15:39:53 +01:00
Jay Bryant
f225df893b Fix for issue #3848
Added the content that didn't get carried forward from 4.2.x.
2021-02-23 12:14:16 +01:00
s.h.bae
f51ed50141 Fix javadoc on ItemReadListener interface
Found after reading some javadocs.
This seems to be a copy & paste mistake.
2021-02-19 13:56:42 +01:00
fhassak
4e02ce7daa Fix javadoc in ExitStatus 2021-02-19 10:21:58 +01:00
Mahmoud Ben Hassine
fc113be4a7 Temporarily ignore intermittently failing tests
This commit temporarily ignores tests that are failing
intermittently on Windows. A link to the corresponding
issue has been added to each test.

FTR, I tried to ignore those tests only on Windows by
using `Assume.assumeFalse(SystemUtils.IS_OS_WINDOWS);`
where `SystemUtils` is from `org.apache.commons.lang3`
but this assumption does not seem to work as expected.
2021-02-18 18:09:40 +01:00
Mahmoud Ben Hassine
29f701cd0c Fix link to STS in README 2021-02-05 16:45:21 +01:00
Mahmoud Ben Hassine
eaeb415521 Remove outdated IDE specific resources 2021-02-05 16:40:47 +01:00
Mahmoud Ben Hassine
329457e672 Remove irrelevant test
The test `testCompareNewWithOldAfterCopy` does
not work on linux/unix unless a `Thread.sleep`
is added before the file copying (see cbcf28c3).

This test does not work on windows neither,
because it is based on apache commons
`FileUtils.copyFile` which does not honor
`preserveFileDate=false` on windows.

The following test works on linux/unix
but not on windows:

```
@Test
public void testLastModifiedAfterCopy() throws IOException {
    File existing = new FileSystemResource(FILE_PATH).getFile();
    File temp = new File("target/temp.txt");
    assertFalse(temp.exists());
    FileUtils.copyFile(existing, temp, false);
    assertTrue(temp.lastModified() > existing.lastModified());
}
```

On windows, even though `preserveFileDate=false`,
the last modification date of the copy is equal
(ie preserved) to the one of the original file,
which is not the case on linux/unix. Trying to
use an alternative like `java.nio.file.Files#copy`
does not work since it only offers the ability
to either copy file attributes or replace the
existing file (which is not the idea of this test).

This test does not add any value and should have
been removed since a long time (see TODO in 12d6613).
2021-02-05 16:28:13 +01:00
Mahmoud Ben Hassine
2cc807de62 Fix tests failing on Windows
Before this commit, tests in this change set
were failing on MS Windows due to the file
comparison method which was based on file
content hash comparison. With this method,
differences between OS line endings
(LF vs CRLF) in generated json files produce
different hashes.

This commit uses a logical json comparison
based on the jsonassert library.
2021-02-04 16:01:22 +01:00
Mahmoud Ben Hassine
ee282ab97f Fix assumption in ScriptItemProcessorTests.testItemBinding
This test fails on Java 15 because the Javascript engine
has been removed in Java 15 (JEP 372).

This commit updates the test to assume that the JavaScript
engine is provided to the JVM through a factory (similar
to other tests).
2021-02-02 13:49:12 +01:00
Mahmoud Ben Hassine
edc13ee0f0 Fix build on Java 11+ 2021-02-02 13:44:56 +01:00
Mahmoud Ben Hassine
fa26246d80 Fix Javadoc errors 2021-02-02 13:43:24 +01:00
Mahmoud Ben Hassine
c5b45f450f Update maven plugins to latest versions 2021-01-29 11:45:34 +01:00
Mahmoud Ben Hassine
d0493906a8 Replace usage of "build" directory with "target" 2021-01-29 11:45:34 +01:00
Mahmoud Ben Hassine
d62f966e68 Add maven-jar-plugin configuration 2021-01-29 11:45:34 +01:00
Mahmoud Ben Hassine
e2b37f4b4c Tweak documentation generation process
* Update and filter distribution resources
* Use maven's `site` phase instead of `verify`
  to generate docs/distribution
2021-01-29 11:45:33 +01:00
Mahmoud Ben Hassine
cde1d41b15 Update build process documentation 2021-01-29 11:45:33 +01:00
Mahmoud Ben Hassine
b1f596cc94 Re-organize dependencies 2021-01-29 11:45:33 +01:00
Mahmoud Ben Hassine
acc1993f6a Add maven deploy plugin 2021-01-29 11:45:33 +01:00
Mahmoud Ben Hassine
ce026b4bf7 Add maven gpg plugin to sign artifacts 2021-01-29 11:45:33 +01:00
Mahmoud Ben Hassine
6477c80e65 Add maven wrapper files 2021-01-29 11:45:32 +01:00
Mahmoud Ben Hassine
49e97b81ee Add maven profile to run test coverage analysis with jacoco 2021-01-29 11:45:32 +01:00
Mahmoud Ben Hassine
91cd55ecaa Update configuration to run unit/integration tests separately
This commit updates the configuration to run unit tests
with maven-surefire-plugin and integration tests with
maven-failsafe-plugin. JSR-352 TCK tests are considered
as integration tests and are executed with other integration
tests (no need for a separate profile to run them).

Some unit tests were failing when integration tests were
skipped.. Those tests have been temporarily ignored.
2021-01-29 11:45:32 +01:00
Mahmoud Ben Hassine
58b80395be Add flatten-maven-plugin configuration 2021-01-29 11:45:32 +01:00
Mahmoud Ben Hassine
d163e13e82 Add jacoco-maven-plugin configuration 2021-01-29 11:45:32 +01:00
Mahmoud Ben Hassine
78e194805f Add maven assembly descriptors to generate distribution 2021-01-29 11:45:32 +01:00
Mahmoud Ben Hassine
8cfec33ef0 Re-organize documentation resources
This commit also adds scaling diagrams [1]
to Figures.ppt. Those diagrams were not under
source control.

[1]: https://docs.spring.io/spring-batch/docs/current/reference/html/spring-batch-integration.html#externalizing-batch-process-execution
2021-01-29 11:45:31 +01:00
Mahmoud Ben Hassine
86ebf9375a Add module to run the JSR-352 TCK 2021-01-29 11:45:31 +01:00
Mahmoud Ben Hassine
fa53dde01e Update build to use Maven instead of Gradle 2021-01-29 11:45:26 +01:00
Mahmoud Ben Hassine
1e433dca85 Fix plugin repositories order in build script
Issue #3823
2021-01-04 14:14:14 +01:00
Mahmoud Ben Hassine
e6ea4bce3d Move docs to src directory 2020-12-04 21:31:00 +01:00
Mahmoud Ben Hassine
236ee88dcf Merge spring-batch-core-tests in spring-batch-core 2020-12-04 16:03:58 +01:00
Mahmoud Ben Hassine
bf612650ea Merge spring-batch-infrastructure-tests in spring-batch-infrastructure 2020-12-04 14:13:33 +01:00
Mahmoud Ben Hassine
afa013f09b Move BatchMessageListenerContainer to src/test 2020-12-04 10:41:22 +01:00
Mahmoud Ben Hassine
f8f5cf2fb4 Fix ignored tests 2020-12-03 17:35:23 +01:00
Mahmoud Ben Hassine
12926b46c9 Remove ignored test
Based on the commit message of df1783a7, this
test has no added value.
2020-12-03 16:01:04 +01:00
Mahmoud Ben Hassine
ac9a0d2718 Remove ignored test suites
Signed-off-by: Mahmoud Ben Hassine <mbenhassine@vmware.com>
2020-12-03 15:38:44 +01:00
Mahmoud Ben Hassine
c8e5e507f4 Polish contribution feb46fd3f7
* Update year in license header
* Use "this" keyword where appropriate
2020-11-27 23:19:24 +01:00