Try to improve CI reliability. (#4787)

* Try to improve CI reliability.

Unset _JAVA_OPTIONS just in case it is causing us to use more memory than expected.

* Replace for loop with foreach.
This commit is contained in:
Gian Merlino 2017-09-12 20:24:45 -07:00 committed by Roman Leventov
parent c3a1ce6933
commit 587f1807c2
2 changed files with 5 additions and 2 deletions

View File

@ -20,11 +20,15 @@ matrix:
# processing module test
- sudo: false
install: echo "MAVEN_OPTS='-Xmx3000m'" > ~/.mavenrc && mvn install -q -ff -DskipTests -B
before_script:
- unset _JAVA_OPTIONS
script: echo "MAVEN_OPTS='-Xmx512m'" > ~/.mavenrc && mvn test -B -Pparallel-test -Dmaven.fork.count=2 -pl processing
# non-processing modules test
- sudo: false
install: echo "MAVEN_OPTS='-Xmx3000m'" > ~/.mavenrc && mvn install -q -ff -DskipTests -B
before_script:
- unset _JAVA_OPTIONS
script: echo "MAVEN_OPTS='-Xmx512m'" > ~/.mavenrc && mvn test -B -Pparallel-test -Dmaven.fork.count=2 -pl '!processing'
# run integration tests

View File

@ -195,8 +195,7 @@ public class JSONPathParser implements Parser<String, Object>
if (val.isArray()) {
List<Object> newList = new ArrayList<>();
for (Iterator<JsonNode> it = val.iterator(); it.hasNext(); ) {
JsonNode entry = it.next();
for (JsonNode entry : val) {
newList.add(valueConversionFunction(entry));
}
return newList;