Search code examples
javaxgboosth2o

h2o build fails with java 15


h2o version: h2o-3.34.0.3 (rel-zizler)

Java version: openjdk version "15.0.2" 2021-01-19 (installed with: FROM adoptopenjdk:15-jre-openj9-focal)

I want to build an XGBoost model using Java 15, but the same code with the same data which runs without issues on Java 14 (openjdk version "14.0.2" 2020-07-14) fails on Java 15, producing the following error messages:

water.exceptions.H2OIllegalArgumentException: Illegal argument: o of function: IcedWrapper: 
    at water.IcedWrapper.<init>(IcedWrapper.java:152) ~[h2o.jar:?]
    at water.util.TwoDimTable.set(TwoDimTable.java:254) ~[h2o.jar:?]
    at water.util.ReproducibilityInformationUtils.createNodeInformationTable(ReproducibilityInformationUtils.java:72) ~[h2o.jar:?]
    at hex.Model$Output.createReproducibilityInformationTable(Model.java:1199) ~[h2o.jar:?]
    at hex.Model$Output.<init>(Model.java:991) ~[h2o.jar:?]
    at hex.Model$Output.<init>(Model.java:973) ~[h2o.jar:?]
    at hex.tree.xgboost.XGBoostOutput.<init>(XGBoostOutput.java:16) ~[h2o.jar:?]
    at hex.tree.xgboost.XGBoost$XGBoostDriver.buildModelImpl(XGBoost.java:419) ~[h2o.jar:?]
    at hex.tree.xgboost.XGBoost$XGBoostDriver.buildModel(XGBoost.java:393) ~[h2o.jar:?]
    at hex.tree.xgboost.XGBoost$XGBoostDriver.computeImpl(XGBoost.java:379) ~[h2o.jar:?]
    at hex.ModelBuilder$Driver.compute2(ModelBuilder.java:246) ~[h2o.jar:?]
    at water.H2O$H2OCountedCompleter.compute(H2O.java:1652) ~[h2o.jar:?]
    at jsr166y.CountedCompleter.exec(CountedCompleter.java:468) ~[h2o.jar:?]
    at jsr166y.ForkJoinTask.doExec(ForkJoinTask.java:263) [h2o.jar:?]
    at jsr166y.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:974) [h2o.jar:?]
    at jsr166y.ForkJoinPool.runWorker(ForkJoinPool.java:1477) [h2o.jar:?]
    at jsr166y.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:104) [h2o.jar:?] 

I launch the h2o server with the following command:

ENTRYPOINT /bin/bash -c "cd h2o && java -XX:+UnlockExperimentalVMOptions -XX:+UseCGroupMemoryLimitForHeap -XX:MaxRAMFraction=1 -XshowSettings:vm -jar h2o.jar

Has anyone came across with similar issues? It looks like a version incompatibility to me, but based on a comment from this, h2o should support Java 15 from version 3.32.1.1 and up. Running H2O with Java 16 on R


Solution

  • Changing Java install to FROM openjdk:15.0.2-jdk-slim has solved the issue