WebLogic12C - 方法_jspService(HttpServletRequest,HttpServletResponse)的代码超过65535字节限制

时间:2017-02-03 14:55:48

标签: jsp weblogic12c jdk1.8.0

我正在处理在WebLogic 10.3.6(JDK 1.6)上运行的旧servlet代码。

我正在尝试使用JDK 1.8和weblogic 12.2.1.0编译此代码。 当我试图用jdk 1.8编译jsp页面时,我看到以下错误。我尝试了以下选项来解决这个问题  1)我尝试了JSP的动态包含  2)我尝试添加

 <servlet>
<servlet-name>jsp</servlet-name>
<servlet-class>org.apache.jasper.servlet.JspServlet</servlet-class>
...
<init-param>
    <param-name>mappedfile</param-name>
    <param-value>false</param-value>
</init-param>
...

两者都不适合我。你能帮帮我吗?我在过去2天里为这个错误而苦苦挣扎。但是还没有得到任何解决方案。

&LT; 2017-02-02T16:21:30.723&GT; &LT; 111&GT; MainServlet.doProcess(Request,Response):处理HTTP请求时出错  --- javax.servlet.ServletException:weblogic.servlet.jsp.CompilationException:无法编译JSP /main/campaign.jsp campaign.jsp:22:1:方法_jspService(HttpServletRequest,HttpServletResponse)的代码超过了65535字节的限制 ^ -----         HREF =&#34;&lt;%= request.getContextPath()%&gt; /include/css/moms_styles.css" ------------- ^

    at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:310)
    at weblogic.servlet.internal.ServletStubImpl.onAddToMapException(ServletStubImpl.java:489)
    at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:376)
    at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:247)
    at weblogic.servlet.internal.RequestDispatcherImpl.invokeServlet(RequestDispatcherImpl.java:625)
    at weblogic.servlet.internal.RequestDispatcherImpl.forward(RequestDispatcherImpl.java:282)
    at com.synapsegroupinc.mvc.controller.MainServlet.handleRequest(MainServlet.java:420)
    at com.synapsegroupinc.mvc.controller.MainServlet.doProcess(MainServlet.java:264)
    at com.synapsegroupinc.mvc.controller.MainServlet.doGet(MainServlet.java:197)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:687)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:790)
    at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:286)
    at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:260)
    at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:137)
    at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:350)
    at weblogic.servlet.internal.TailFilter.doFilter(TailFilter.java:25)
    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:78)
    at com.synapsegroupinc.moms.util.web.model.MomsUserContextFilter.doFilter(MomsUserContextFilter.java:116)
    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:78)
    at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.wrapRun(WebAppServletContext.java:3683)
    at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3649)
    at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:326)
    at weblogic.security.service.SecurityManager.runAsForUserCode(SecurityManager.java:197)
    at weblogic.servlet.provider.WlsSecurityProvider.runAsForUserCode(WlsSecurityProvider.java:203)
    at weblogic.servlet.provider.WlsSubjectHandle.run(WlsSubjectHandle.java:71)
    at weblogic.servlet.internal.WebAppServletContext.doSecuredExecute(WebAppServletContext.java:2433)
    at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2281)
    at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2259)
    at weblogic.servlet.internal.ServletRequestImpl.runInternal(ServletRequestImpl.java:1691)
    at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1651)
    at weblogic.servlet.provider.ContainerSupportProviderImpl$WlsRequestExecutor.run(ContainerSupportProviderImpl.java:270)
    at weblogic.invocation.ComponentInvocationContextManager._runAs(ComponentInvocationContextManager.java:348)
    at weblogic.invocation.ComponentInvocationContextManager.runAs(ComponentInvocationContextManager.java:333)
    at weblogic.work.LivePartitionUtility.doRunWorkUnderContext(LivePartitionUtility.java:54)
    at weblogic.work.PartitionUtility.runWorkUnderContext(PartitionUtility.java:41)
    at weblogic.work.SelfTuningWorkManagerImpl.runWorkUnderContext(SelfTuningWorkManagerImpl.java:640)
    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:406)
    at weblogic.work.ExecuteThread.run(ExecuteThread.java:346)

2 个答案:

答案 0 :(得分:0)

尝试拆分jsp页面并使用include jsp。它会减少代码和大小。

答案 1 :(得分:0)

这是一个已在 oracle 上报告的错误。

<块引用>

错误 25294832:WLS 12.2.1.2 部署错误方法_JSPSERVICE 超过 65535 字节限制

请使用 bug id 和 support.oracle.com 来解决这个问题。