在Java 8和之前的版本中,存在使用支持目录(java.endorsed.dirs)的机制,该目录是覆盖JDK内部实现的库集合。
我怎样才能在Java 9中解决这个问题。在那里删除了被删除的dirs?
在Java 8和之前的版本中,存在使用支持目录(java.endorsed.dirs)的机制,该目录是覆盖JDK内部实现的库集合。
我怎样才能在Java 9中解决这个问题。在那里删除了被删除的dirs?
在JDK 9中,您可以使用 可升级的模块 或者说 类路径上的JAR文件。
该 Java 9迁移指南 状态:
该
java.endorsed.dirs
系统属性和lib/endorsed
目录不再存在。该javac
编译器和java
如果检测到任何一个,启动器将退出。
如果存在以下任何一种情况,您最终会发现错误:
<JAVA_HOME>/lib/endorsed is not supported. Endorsed standards and standalone APIs in modular form will be supported via the concept of upgradeable modules. Error: Could not create the Java Virtual Machine. Error: A fatal exception has occurred. Program will exit.
这些认可的标准覆盖机制被删除以实现 模块化运行时映像 现在将使用模块化图像。
模块化图像由模块而不是JAR文件组成。展望 支持转发,认可标准和独立API 只有模块化形式,通过概念 可升级的模块。
I also faced same issue, Java versions higher than 8 are not supported by Tomcat 9.
please check bin/catalina.sh for more information.
#JAVA_ENDORSED_DIRS (Optional) Lists of of colon separated directories
#containing some jars in order to allow replacement of APIs
#created outside of the JCP (i.e. DOM and SAX from W3C).
#It can also be used to update the XML parser implementation.
#This is only supported for Java <= 8.
#Defaults to $CATALINA_HOME/endorsed.
在JDK 9中,您可以使用 可升级的模块 或者说 类路径上的JAR文件。
该 Java 9迁移指南 状态:
该
java.endorsed.dirs
系统属性和lib/endorsed
目录不再存在。该javac
编译器和java
如果检测到任何一个,启动器将退出。
如果存在以下任何一种情况,您最终会发现错误:
<JAVA_HOME>/lib/endorsed is not supported. Endorsed standards and standalone APIs in modular form will be supported via the concept of upgradeable modules. Error: Could not create the Java Virtual Machine. Error: A fatal exception has occurred. Program will exit.
这些认可的标准覆盖机制被删除以实现 模块化运行时映像 现在将使用模块化图像。
模块化图像由模块而不是JAR文件组成。展望 支持转发,认可标准和独立API 只有模块化形式,通过概念 可升级的模块。
I also faced same issue, Java versions higher than 8 are not supported by Tomcat 9.
please check bin/catalina.sh for more information.
#JAVA_ENDORSED_DIRS (Optional) Lists of of colon separated directories
#containing some jars in order to allow replacement of APIs
#created outside of the JCP (i.e. DOM and SAX from W3C).
#It can also be used to update the XML parser implementation.
#This is only supported for Java <= 8.
#Defaults to $CATALINA_HOME/endorsed.