我正在尝试安装AEM。我可以先打开它加载的快速启动。但是,当在浏览器(https://localhost:8080)中打开它时,它给出了一个错误“无法为JSP编译类”。请找到完整的错误:
Unable to compile class for JSP: An error occurred at line: 95 in the jsp
file: /libs/granite/core/components/login/login.jsp
The type java.lang.CharSequence cannot be resolved.
It is indirectly referenced from required .class files
92: ?request.getParameter(PARAM_NAME_REASON)
93: : "";
94:
95: if (!StringUtils.isEmpty(reason)) {
96: if (validReasons.containsKey(reason)) {
97: reason = validReasons.get(reason);
98: } else {
An error occurred at line: 95 in the jsp file:
/libs/granite/core/components/login/login.jsp
The method isEmpty(CharSequence) in the type StringUtils is not applicable for the arguments (String)
92: ? request.getParameter(PARAM_NAME_REASON)
93: : "";
94:
95: if (!StringUtils.isEmpty(reason)) {
96: if (validReasons.containsKey(reason)) {
97: reason = validReasons.get(reason);
98: } else {
Cannot serve request to /libs/granite/core/content/login.html in /libs/granite/core/components/login/login.jsp
请同样帮助我。
答案 0 :(得分:2)
当您尝试使用JDK的更高版本运行AEM时,通常会发生此错误(最常见的是运行带有Java 8的vanilla AEM 6.0)。
如果是这种情况,请恢复为JDK7或安装支持JDK 8的AEM 6.0的Service Pack 2.
有关安装Service Pack以解决此问题的步骤,请参阅Adobe论坛中的this thread。