我已经为login.jsp创建了登录片段,它完全正常。
现在我需要添加一些代码来从自定义表中获取一些数据,所以我使用scriptlet添加了XYZLocalServiceUtil调用。
现在服务调用正在运行,但问题是当我部署片段钩子时它会出现以下错误并且portlet变得不可用,但仅在部署后第一次出现。
当我刷新页面时,下次正常工作时没有任何错误。我不确定为什么它第一次无法获得以下依赖。
07:17:00,237 ERROR [http-nio-9080-exec-9][PortletRequestDispatcherImpl:265] Unable to dispatch request: javax.el.ELException: Provider com.sun.el.ExpressionFactoryImpl not found 07:17:00,242 ERROR [http-nio-9080-exec-9][PortletServlet:111] javax.portlet.PortletException: org.apache.jasper.JasperException: javax.el.ELException: Provider com.sun.el.ExpressionFactoryImpl not found javax.portlet.PortletException: org.apache.jasper.JasperException: javax.el.ELException: Provider com.sun.el.ExpressionFactoryImpl not found at com.liferay.portlet.PortletRequestDispatcherImpl.dispatch(PortletRequestDispatcherImpl.java:267) at com.liferay.portlet.PortletRequestDispatcherImpl.include(PortletRequestDispatcherImpl.java:102) at com.liferay.portal.kernel.portlet.bridges.mvc.MVCPortlet.include(MVCPortlet.java:594) at com.liferay.portal.kernel.portlet.bridges.mvc.MVCPortlet.include(MVCPortlet.java:610) at com.liferay.portal.kernel.portlet.bridges.mvc.MVCPortlet.doView(MVCPortlet.java:160) at com.liferay.portal.kernel.portlet.LiferayPortlet.doDispatch(LiferayPortlet.java:303) at com.liferay.portal.kernel.portlet.bridges.mvc.MVCPortlet.doDispatch(MVCPortlet.java:497) at javax.portlet.GenericPortlet.render(GenericPortlet.java:262) at com.liferay.portal.kernel.portlet.bridges.mvc.MVCPortlet.render(MVCPortlet.java:317) at com.liferay.portlet.FilterChainImpl.doFilter(FilterChainImpl.java:103) at com.liferay.portlet.ScriptDataPortletFilter.doFilter(ScriptDataPortletFilter.java:57) at com.liferay.portlet.FilterChainImpl.doFilter(FilterChainImpl.java:100) at com.liferay.portal.kernel.portlet.PortletFilterUtil.doFilter(PortletFilterUtil.java:64) at com.liferay.portal.kernel.servlet.PortletServlet.service(PortletServlet.java:107) at javax.servlet.http.HttpServlet.service(HttpServlet.java:729) at org.eclipse.equinox.http.servlet.internal.registration.EndpointRegistration.service(EndpointRegistration.java:153) at org.eclipse.equinox.http.servlet.internal.servlet.ResponseStateHandler.processRequest(ResponseStateHandler.java:62) at org.eclipse.equinox.http.servlet.internal.context.DispatchTargets.doDispatch(DispatchTargets.java:117) at org.eclipse.equinox.http.servlet.internal.servlet.RequestDispatcherAdaptor.include(RequestDispatcherAdaptor.java:48) at com.liferay.portlet.InvokerPortletImpl.invoke(InvokerPortletImpl.java:530) at com.liferay.portlet.InvokerPortletImpl.invokeRender(InvokerPortletImpl.java:605) at com.liferay.portlet.InvokerPortletImpl.render(InvokerPortletImpl.java:391) at com.liferay.portal.monitoring.internal.portlet.MonitoringInvokerPortlet.render(MonitoringInvokerPortlet.java:265) at org.apache.jsp.html.portal.render_005fportlet_jsp._jspService(render_005fportlet_jsp.java:1580) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70) at javax.servlet.http.HttpServlet.service(HttpServlet.java:729) at com.liferay.portal.servlet.DirectRequestDispatcher.include(DirectRequestDispatcher.java:64) at com.liferay.portal.servlet.ClassLoaderRequestDispatcherWrapper.doDispatch(ClassLoaderRequestDispatcherWrapper.java:78) at com.liferay.portal.servlet.ClassLoaderRequestDispatcherWrapper.include(ClassLoaderRequestDispatcherWrapper.java:53) at com.liferay.portlet.PortletContainerImpl._render(PortletContainerImpl.java:707) at com.liferay.portlet.PortletContainerImpl.render(PortletContainerImpl.java:162) at com.liferay.portlet.SecurityPortletContainerWrapper.render(SecurityPortletContainerWrapper.java:133) at com.liferay.portlet.RestrictPortletContainerWrapper.render(RestrictPortletContainerWrapper.java:133) ...
我试过在gradle文件中添加以下依赖项但没有运气。 编译组:'org.glassfish',名称:'javax.el',版本:'3.0.0'
我正在使用“liferay-ce-portal-7.0-ga4”,如果有人遇到类似问题,请提出解决问题的方法。
由于