Struts 2-格式不正确的OGNL表达式:{1}()遇到““)”(空白表达式)

时间:2019-07-15 21:15:42

标签: jsp struts2

我们有一个Struts 2应用程序,在执行页面操作时偶尔会失败并显示以下错误,

ognl.ExpressionSyntaxException: Malformed OGNL expression: {1}() 
[ognl.ParseException: Encountered " ")" ") "" at line 1, column 5. 
Was expecting one of: ":" ... "not" ... "+" ... "-" ... "~" ... "!" ... "("       
... "true" ... "false" ... "null" ... "#this" ... "#root" ... "#" ... "[" 
... "{" ... "@" ... "new" ... ... ... "\'" ... "`" ... "\"" ... ... ... ] at 
ognl.Ognl.parseExpression(Ognl.java:112) at 

com.opensymphony.xwork2.ognl.OgnlUtil.compileAndExecuteMethod(OgnlUtil.java:442) at com.opensymphony.xwork2.ognl.OgnlUtil.callMethod(OgnlUtil.java:396) at com.opensymphony.xwork2.DefaultActionInvocation.invokeAction(DefaultActionInvocation.java:430) at com.opensymphony.xwork2.DefaultActionInvocation.invokeActionOnly(DefaultActionInvocation.java:290) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:251) at org.apache.struts2.interceptor.DeprecationInterceptor.intercept(DeprecationInterceptor.java:41) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:245) at org.apache.struts2.interceptor.debugging.DebuggingInterceptor.intercept(DebuggingInterceptor.java:256) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:245) at com.opensymphony.xwork2.interceptor.DefaultWorkflowInterceptor.doIntercept(DefaultWorkflowInterceptor.java:168) at com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:98) at com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:245) at com.opensymphony.xwork2.validator.ValidationInterceptor.doIntercept(ValidationInterceptor.java:265) at org.apache.struts2.interceptor.validation.AnnotationValidationInterceptor.doIntercept(AnnotationValidationInterceptor.java:76) at

()中有时似乎缺少Struts表达式。

有时,当页面闲置时间过长并单击按钮时会发生这种情况,但是有时没有超时。

没有简单的方法可以进行调试或调查,有什么提示吗?无法始终如一地复制。

0 个答案:

没有答案