我正在使用Alfresco 3.4版。 在调用Java支持的webscript时,我在事务(stackoverflow,读取日志)错误中收到异常。
HTTP响应的格式类似于
<div>
<table>
<tbody><tr>
<td><img src="/alfresco/images/logo/AlfrescoLogo32.png" alt="Alfresco"></td>
<td><span class="title">Web Script Status 500 - Internal Error</span></td>
</tr>
</tbody></table>
<br>
<table>
<tbody><tr><td>The Web Script <a href="/path/to/webscript/and/its/name.post">/path/to/webscript/and/its/name.post</a> has responded with a status of 500 - Internal Error.</td></tr>
</tbody></table>
<br>
<table>
<tbody><tr><td><b>500 Description:</b></td><td> An error inside the HTTP server which prevented it from fulfilling the request.</td></tr>
<tr><td> </td></tr>
<tr><td><b>Message:</b></td><td>07212496 Exception in Transaction.</td></tr>
<tr><td></td><td> </td></tr>
<tr><td><b>Exception:</b></td><td>org.alfresco.error.AlfrescoRuntimeException - 07212496 Exception in Transaction.</td></tr>
<tr><td></td><td> </td></tr>
<tr><td></td><td>org.alfresco.repo.transaction.RetryingTransactionHelper.doInTransaction(RetryingTransactionHelper.java:461)</td></tr>
<tr><td></td><td> </td></tr>
<tr><td><b>Server</b>:</td><td>Community v3.4.0 (c 3335) schema 4.113</td></tr>
<tr><td><b>Time</b>:</td><td>21.08.2014. 11:10:31</td></tr>
<tr><td></td><td> </td></tr>
<tr><td><b>Diagnostics</b>:</td><td><a href="/path/to/webscript/and/its/name.post">Inspect Web Script (path/to/webscript/and/its/name.post)</a></td></tr>
</tbody></table>
</div>
在日志中,我可以阅读
14:29:20,548 ERROR [extensions.webscripts.AbstractRuntime] Exception from executeScript - redirecting to status template error: 07217738 Exception in Transaction.
org.alfresco.error.AlfrescoRuntimeException: 07217738 Exception in Transaction.
at org.alfresco.repo.transaction.RetryingTransactionHelper.doInTransaction(RetryingTransactionHelper.java:461)
at org.alfresco.repo.web.scripts.RepositoryContainer.transactionedExecute(RepositoryContainer.java:436)
at org.alfresco.repo.web.scripts.RepositoryContainer.transactionedExecuteAs(RepositoryContainer.java:466)
at org.alfresco.repo.web.scripts.RepositoryContainer.executeScript(RepositoryContainer.java:304)
at org.springframework.extensions.webscripts.AbstractRuntime.executeScript(AbstractRuntime.java:333)
at org.springframework.extensions.webscripts.AbstractRuntime.executeScript(AbstractRuntime.java:189)
at org.springframework.extensions.webscripts.servlet.WebScriptServlet.service(WebScriptServlet.java:118)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.alfresco.web.app.servlet.GlobalLocalizationFilter.doFilter(GlobalLocalizationFilter.java:58)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:298)
at org.apache.coyote.http11.Http11AprProcessor.process(Http11AprProcessor.java:859)
at org.apache.coyote.http11.Http11AprProtocol$Http11ConnectionHandler.process(Http11AprProtocol.java:579)
at org.apache.tomcat.util.net.AprEndpoint$Worker.run(AprEndpoint.java:1555)
at java.lang.Thread.run(Thread.java:619)
Caused by: java.lang.StackOverflowError
at org.alfresco.repo.management.subsystems.AbstractPropertyBackedBean.start(AbstractPropertyBackedBean.java:451)
at org.alfresco.repo.management.subsystems.AbstractPropertyBackedBean.start(AbstractPropertyBackedBean.java:440)
at org.alfresco.repo.management.subsystems.AbstractPropertyBackedBean.getState(AbstractPropertyBackedBean.java:221)
at org.alfresco.repo.management.subsystems.ChildApplicationContextFactory.getApplicationContext(ChildApplicationContextFactory.java:336)
at org.alfresco.repo.management.subsystems.SubsystemProxyFactory$1.invoke(SubsystemProxyFactory.java:69)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:202)
at $Proxy40.isTransformable(Unknown Source)
at sun.reflect.GeneratedMethodAccessor418.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.alfresco.repo.management.subsystems.SubsystemProxyFactory$1.invoke(SubsystemProxyFactory.java:71)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:202)
at $Proxy40.isTransformable(Unknown Source)
at sun.reflect.GeneratedMethodAccessor418.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.alfresco.repo.management.subsystems.SubsystemProxyFactory$1.invoke(SubsystemProxyFactory.java:71)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:172)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:202)
at $Proxy40.isTransformable(Unknown Source)
at sun.reflect.GeneratedMethodAccessor418.invoke(Unknown Source)
由于它支持java的webscript,我调试了整个代码,没有异常或类似的东西。我增加了线程堆栈大小,因为我使用的是开发环境。我已经没想到要尝试更多的东西了。