Changeset 3c0ba5c for apps


Ignore:
Timestamp:
Jan 1, 2019 3:01:22 PM (17 months ago)
Author:
zzz <zzz@…>
Branches:
master
Children:
92ad4d1
Parents:
f221e72
Message:

Console: Add warning for OpenJDK Zero VM

File:
1 edited

Legend:

Unmodified
Added
Removed
  • apps/routerconsole/java/src/net/i2p/router/web/RouterConsoleRunner.java

    rf221e72 r3c0ba5c  
    345345                            !FileUtil.isPack200Supported();
    346346        boolean openARM = SystemVersion.isARM() && SystemVersion.isOpenJDK() && !SystemVersion.isJava9();
     347        boolean isZero = SystemVersion.isZeroVM();
    347348        boolean isJava11 = false; // SystemVersion.isJava11();
    348         if (noJava7 || noPack200 || openARM || isJava11) {
     349        if (noJava7 || noPack200 || openARM || isZero || isJava11) {
    349350            String s = "Java version: " + System.getProperty("java.version") +
    350351                       " OS: " + System.getProperty("os.name") + ' ' +
     
    366367            if (openARM) {
    367368                s = "OpenJDK 7/8 are not recommended for ARM. Use OpenJDK 9 (or higher) or Oracle Java 8 (or higher)";
     369                log.logAlways(net.i2p.util.Log.WARN, s);
     370                System.out.println("Warning: " + s);
     371            }
     372            if (isZero) {
     373                s = "OpenJDK Zero is a very slow interpreter-only JVM. Not recommended for use with I2P. Please use a faster JVM if possible.";
    368374                log.logAlways(net.i2p.util.Log.WARN, s);
    369375                System.out.println("Warning: " + s);
Note: See TracChangeset for help on using the changeset viewer.