Commit Graph

5319 Commits

Author SHA1 Message Date
Yanming Zhou
6c5476780e Treat MariaDB as MySQL
MariaDB is a fork of MySQL
2019-02-13 15:25:52 -06:00
Mahmoud Ben Hassine
ce9a359626 Rename StepContext#getJobId to StepContext#getJobInstanceId
There is no such concept of job Id. A job has a name but not an Id.
A job instance however has an Id. The goal of the getter suggested in
BATCH-2769 is to access the JobInstance Id.

This commit renames the newly added StepContext#getJobId to
StepContext#getJobInstanceId which is more explicit.

Resolves BATCH-2769
2019-02-04 12:59:20 +01:00
Mahmoud Ben Hassine
ffe158cade Fix concurrency issue in RetryTransactionalPollingIntegrationTests 2019-02-01 11:54:12 +01:00
Mahmoud Ben Hassine
797fe1b20a Re-initialize datasource before each integration test 2019-01-30 22:31:04 +01:00
Mahmoud Ben Hassine
422c233e3c Fix integration tests 2019-01-30 14:12:55 +01:00
Mahmoud Ben Hassine
7e9cd07cbb Fix Javadoc errors 2019-01-30 09:30:08 +01:00
Mahmoud Ben Hassine
fbe345630b Fix build warnings 2019-01-29 23:36:53 +01:00
Mahmoud Ben Hassine
177856ffd7 Remove unused dependencies 2019-01-29 22:26:38 +01:00
Mahmoud Ben Hassine
8ae64e8e0a Remove MaxPermSize option from build as it was removed in Java 8
This commit fixes the warning:

```
Java HotSpot(TM) 64-Bit Server VM warning:
ignoring option MaxPermSize=256m; support was removed in 8.0
```
2019-01-29 21:42:36 +01:00
Mahmoud Ben Hassine
3ca4284715 Upgrade SF to version 5.2.0.BUILD-SNAPSHOT and remove Castor tests
Castor support will be removed in SF v5.2. This commit removes
CastorMarshallingTests and CastorUnmarshallingTests as they do not
compile with SF v5.2.0.BUILD-SNAPSHOT.

Resolves BATCH-2787
2019-01-29 21:07:28 +01:00
Mahmoud Ben Hassine
0ec945614b Upgrade gradle to version 4.10.3 2019-01-29 19:43:35 +01:00
Mahmoud Ben Hassine
197f32eb21 Fix gradle warnings
This commit fixes the following warnings:

```
$ ./gradlew clean --warning-mode all

> Configure project :

The Task.leftShift(Closure) method has been deprecated.
This is scheduled to be removed in Gradle 5.0.
Please use Task.doLast(Action) instead.
 at build_1u4zf89udullsb7m3yccjzfxt$_run_closure3.doCall(/spring-batch/build.gradle:187)
 (Run with --stacktrace to get the full stack trace of this deprecation warning.)

Creating a custom task named 'wrapper' has been deprecated.
This is scheduled to be removed in Gradle 5.0.
You can configure the existing task using the 'wrapper { }' syntax or
create your custom task under a different name.
 at build_1u4zf89udullsb7m3yccjzfxt.run(/spring-batch/build.gradle:921)
 (Run with --stacktrace to get the full stack trace of this deprecation warning.)

BUILD SUCCESSFUL in 3s
10 actionable tasks: 1 executed, 9 up-to-date
```

It also fixes the following warning about annotation processing:

```
Detecting annotation processors on the compile classpath has been deprecated.
Gradle 5.0 will ignore annotation processors on the compile classpath.
If you did not intend to use annotation processors,
you can use the '-proc:none' compiler argument to ignore them.
```

References:

* Spring Boot issue #6421
* https://discuss.gradle.org/t/regarding-the-annotation-processors-on-compile-classpath-warning-in-gradle-4-6
2019-01-29 19:42:41 +01:00
Mahmoud Ben Hassine
42596920e6 Remove Travis CI build descriptor
Spring Batch CI build runs on Bamboo at Pivotal. There is no need for a
third party service to build the project.
2019-01-28 11:45:43 +01:00
Mahmoud Ben Hassine
21c14fc281 Upgrade dependencies 2019-01-28 11:42:20 +01:00
Mahmoud Ben Hassine
eba7265a95 Fix tests failing randomly
Tests modified in this change set fail randomly due to shared
mutable state between multiple threads.

This commit ensures that the shared state is correctly
synchronised between threads or re-initialized before each test run.
2019-01-28 10:31:43 +01:00
Mahmoud Ben Hassine
c9f72cd2c1 Minor polish 2019-01-25 17:38:28 +01:00
Mahmoud Ben Hassine
1bfabeb33c Fix tests failing on windows
The command `ping 1.1.1.1 -n 1 -w 5000` sends only one packet to the
remote address and might finish before the configured timeout of 10ms
which makes some tests to fail. Moreover, pinging 1.1.1.1 requires the
host (which can be the CI build server) to have internet connection.
This command can also fail if there is no internet connection which
makes some tests (expecting the command to succeed) to fail too.

This commit uses the command `ping 127.0.0.1` which does not require
an internet connection and which will, by default [1], send 4 packets
and wait for a timeout of 4 seconds for each request. This should take
more time than the configured timeout of 10ms.

Resolves BATCH-2722

[1]: https://docs.microsoft.com/en-us/windows-server/administration/windows-commands/ping
2019-01-25 17:37:18 +01:00
Sean Sullivan
951bfc970b Upgrade activemq to version 5.15.8 2019-01-21 15:03:25 +01:00
Sean Sullivan
ab959717f3 Upgrade jackson to version 2.9.8 2019-01-21 15:01:11 +01:00
Mahmoud Ben Hassine
90a89c1b02 Fix JobOperatorFunctionalTests#testMultipleSimultaneousInstances
The `testMultipleSimultaneousInstances` test uses a SimpleAsyncTaskExecutor.
This means when a job is submitted, a new thread will be created to run
the job. However, there could be a small time interval between
JobOperator.startNextInstance(job) and
JobOperator.findRunningExecutions(job) where the job execution is created
but not started yet. When this happens, the test fails as
`findRunningExecutions` does not return the just created
(but not started yet) execution.

This commit adds a `Thread.sleep` between these two invocations in order
to give a chance to the background thread (to be created and) to execute
the job.
2019-01-15 20:51:56 +01:00
Mahmoud Ben Hassine
5f0f7c494b Fix code example in docs
`StepExecution#setTerminateOnly` does not take a boolean parameter.
2019-01-15 15:34:02 +01:00
Mahmoud Ben Hassine
edfbdbb82a Tweak XmlInputFactory settings 2019-01-14 14:47:10 +01:00
Mahmoud Ben Hassine
7ca11f2f99 Add assertion that a serializer was set in the JdbcExecutionContextDao
Resolves BATCH-2779
2019-01-09 16:11:47 -06:00
Mahmoud Ben Hassine
2a578ae663 Remove unused imports 2019-01-03 23:18:58 +01:00
Mahmoud Ben Hassine
a5748136d2 Fix typos 2019-01-03 23:00:19 +01:00
Drummond Dawson
fa62861015 BATCH-2771: Fix deprecations in DefaultDataFieldMaxValueIncrementerFactory 2018-11-29 15:33:31 +01:00
Mahmoud Ben Hassine
76c34c7f72 fix build warnings 2018-11-29 15:17:01 +01:00
Mahmoud Ben Hassine
e5ac0e9975 Polish 2f0c2a6772 2018-11-28 22:32:11 +01:00
Drummond Dawson
2f0c2a6772 BATCH-2761: Varargs in reader, processor, and writer builders
If a builder has a builder method that takes a List, it should also provide a builder method that takes a varargs.
2018-11-28 20:34:11 +01:00
Olivier Bourgain
2ee15d2f4c Remove call to String.toCharArray 2018-11-28 15:06:58 +01:00
clf
f90198fef8 fix wrong Java Configuration for In-Memory JobRepository 2018-11-26 12:14:39 +01:00
Mahmoud Ben Hassine
ed84a8cb29 Fix id of scalability#partitioner section in documentation 2018-11-16 11:24:35 +01:00
Nicolas Widart
131e02e3a3 Add a getJobId convenience method to StepContext
Resolves BATCH-2769
2018-11-07 10:33:05 +01:00
Drummond Dawson
42c0614742 Replace explicit type with diamond operator in test module 2018-11-06 21:30:36 +01:00
Drummond Dawson
e4dd5d9c60 Replace explicit type with diamond operator in samples module 2018-11-06 21:27:39 +01:00
Drummond Dawson
3fe5fc3427 Replace explicit type with diamond operator in integration module 2018-11-06 21:23:43 +01:00
Drummond Dawson
eb9e0d1466 Replace explicit type with diamond operator in infrastructure tests module 2018-11-06 21:20:11 +01:00
Drummond Dawson
424514a17b Replace explicit type with diamond operator in infrastructure module 2018-11-06 21:03:33 +01:00
Drummond Dawson
3902837c3c Replace explicit type with diamond operator in docs module 2018-11-06 21:00:27 +01:00
Drummond Dawson
5ebf09e356 Replace explicit type with diamond operator in core tests module 2018-11-06 20:56:00 +01:00
Drummond Dawson
4192bfe01e Replace explicit type with diamond operator in core module 2018-11-06 20:28:08 +01:00
Dimitrios Liapis
e707a57157 Fix javadoc typo in PartitionStepBuilder#gridSize()
Resolves BATCH-2768
2018-11-06 17:07:59 +01:00
Mahmoud Ben Hassine
9e02e935ce Return null instead of 0 when a Long/Double job parameter is absent
Resolves BATCH-2385
2018-11-02 22:21:13 +01:00
Mahmoud Ben Hassine
2d7caa3222 Fix typo
Resolves BATCH-2758
2018-11-02 21:52:40 +01:00
Spring Buildmaster
3a48584f3f [artifactory-release] Next development version 2018-10-29 20:10:11 +00:00
Spring Buildmaster
16320b9c2f [artifactory-release] Release version 4.1.0.RELEASE 2018-10-29 20:10:05 +00:00
Mahmoud Ben Hassine
c7994295b7 Update the "What's new section" with features of version 4.1.0.RELEASE 2018-10-29 18:48:01 +01:00
Mahmoud Ben Hassine
cb6e34e5d6 Upgrade dependencies for version 4.1.0.RELEASE 2018-10-29 18:35:06 +01:00
Mahmoud Ben Hassine
fb4494b0d0 Add migration script to use characters instead of bytes for oracle db
Resolves BATCH-2091
2018-10-29 10:04:16 -05:00
David J. M. Karlsen
4283291cc8 use VARCHAR( n char) instead of VARCHAR(n) so semantics are used and not number of bytes. This is better when using multibyte charsets like UTF8 2018-10-29 10:04:10 -05:00