我目前只需要交叉编译几个针对Java 8的JAR(在我的Java 11应用程序中),因为VoltDB仅支持在DDL电压8.4.x以下加载Java 8 JAR。理想情况下,我只想使用Java 11,因为Java 8在商业上不再受支持。
查看voltDB 9.0的发行说明后,我看到了对Java 11的支持。首先,我尝试了voltdb网站上的社区版本,该版本不会加载使用Java 11编译的JAR。因此,我去了github并克隆了标记版本“ voltdb-9.0”。我尝试使用Java 11.0.3构建“蚂蚁”。失败并显示以下跟踪:
compile_core:
[mkdir] Created dir: /home/paul/Code/voltdb/obj/release/test
[mkdir] Created dir: /home/paul/Code/voltdb/obj/release/testprocs
[mkdir] Created dir: /home/paul/Code/voltdb/obj/release/testfuncs
[copy] Copying 18 files to /home/paul/Code/voltdb/obj/release/prod
[copy] Copying 3 files to /home/paul/Code/voltdb/obj/release/prod/org/hsqldb_voltpatches/resources
[copy] Copying 82 files to /home/paul/Code/voltdb/obj/release/prod/org/voltdb/dbmonitor
[copy] Copying 36 files to /home/paul/Code/voltdb/temp/js
[copy] Copying 36 files to /home/paul/Code/voltdb/temp/js
[move] Moving 36 files to /home/paul/Code/voltdb/obj/release/prod/org/voltdb/dbmonitor/js
[delete] Deleting directory /home/paul/Code/voltdb/temp
[copy] Copying 1 file to /home/paul/Code/voltdb/obj/release/prod
[copy] Copying 1 file to /home/paul/Code/voltdb/obj/release/prod
[copy] Copying 69 files to /home/paul/Code/voltdb/obj/release/test
[copy] Copying 3 files to /home/paul/Code/voltdb/obj/release/prod
[copy] Copying 20 files to /home/paul/Code/voltdb/obj/release/testprocs
[copy] Copying 2 files to /home/paul/Code/voltdb/obj/release/testprocs
[copy] Copying 3 files to /home/paul/Code/voltdb/obj/release/test/org/hsqldb_voltpatches
[javac] Compiling 378 source files to /home/paul/Code/voltdb/obj/release/prod
[javac] /home/paul/Code/voltdb/src/hsqldb19b3/org/hsqldb_voltpatches/jdbc/JDBCPreparedStatement.java:762: warning: [dep-ann] deprecated item is not annotated with @Deprecated
[javac] public synchronized void setUnicodeStream(int parameterIndex,
[javac] ^
[javac] /home/paul/Code/voltdb/src/hsqldb19b3/org/hsqldb_voltpatches/jdbc/JDBCCallableStatement.java:734: warning: [dep-ann] deprecated item is not annotated with @Deprecated
[javac] public synchronized BigDecimal getBigDecimal(int parameterIndex,
[javac] ^
[javac] /home/paul/Code/voltdb/src/hsqldb19b3/org/hsqldb_voltpatches/jdbc/JDBCResultSet.java:631: warning: [dep-ann] deprecated item is not annotated with @Deprecated
[javac] public BigDecimal getBigDecimal(int columnIndex,
[javac] ^
[javac] /home/paul/Code/voltdb/src/hsqldb19b3/org/hsqldb_voltpatches/jdbc/JDBCResultSet.java:876: warning: [dep-ann] deprecated item is not annotated with @Deprecated
[javac] public java.io.InputStream getUnicodeStream(
[javac] ^
[javac] /home/paul/Code/voltdb/src/hsqldb19b3/org/hsqldb_voltpatches/jdbc/JDBCResultSet.java:1099: warning: [dep-ann] deprecated item is not annotated with @Deprecated
[javac] public BigDecimal getBigDecimal(String columnLabel,
[javac] ^
[javac] /home/paul/Code/voltdb/src/hsqldb19b3/org/hsqldb_voltpatches/jdbc/JDBCResultSet.java:1242: warning: [dep-ann] deprecated item is not annotated with @Deprecated
[javac] public java.io.InputStream getUnicodeStream(
[javac] ^
[javac] /home/paul/Code/voltdb/src/hsqldb19b3/org/hsqldb_voltpatches/lib/java/JavaSystem.java:195: error: cannot find symbol
[javac] System.runFinalizersOnExit(true);
[javac] ^
[javac] symbol: method runFinalizersOnExit(boolean)
[javac] location: class System
[javac] Note: Some input files use or override a deprecated API.
[javac] Note: Recompile with -Xlint:deprecation for details.
[javac] Note: Some input files use unchecked or unsafe operations.
[javac] Note: Recompile with -Xlint:unchecked for details.
[javac] 1 error
[javac] 6 warnings
BUILD FAILED
/home/paul/Code/voltdb/build.xml:1390: The following error occurred while executing this line:
/home/paul/Code/voltdb/build.xml:33: Compile failed; see the compiler error output for details.
VoltDB网站上只有较旧版本的旧版本说明。有人可以帮我将其编译为Java 11吗?
答案 0 :(得分:0)
VoltDB v9.0将在Java 11上运行,但是如果您从源代码进行编译,暂时仍需要使用Java 8进行编译。披露:我在VoltDB工作。