Avoid using _JAVA_OPTIONS in Travis builds

Description

We see this kind of messages in the logs of Travis builds each time a JVM is spawned:

This comes from Travis setting up the _JAVA_OPTIONS environment variable in container environments.

The goal is to limit the amount of memory used by JVMs in containers, which is fine. Unfortunately, the _JAVA_OPTIONS environment variable takes precedence over arguments passed in the command line, such as Elasticsearch servers we spawn during the Maven build, and this ends up raising the amount of memory used by some JVMs, and sometimes makes the build fail.

See also https://github.com/travis-ci/travis-ci/issues/8408

We should unset this environment variable in our .travis.yml, and either move its value to JAVA_TOOLS_OPTIONS, which does not take precedence over command line arguments, or simply ignore it.

See also https://stackoverflow.com/questions/28327620/difference-between-java-options-java-tool-options-and-java-opts

Environment

None

Status

Assignee

Yoann Rodière

Reporter

Yoann Rodière

Labels

None

Suitable for new contributors

None

Feedback Requested

None

Components

Priority

Major
Configure