HTTP Status 500 - org.apache.struts2.json.JSONException:
struts2.3+spring4.1 action执行完成后,抛出异常!
HTTP Status 500 - org.apache.struts2.json.JSONException: org.apache.struts2.json.JSONException: org.apache.struts2.json.JSONException: org.apache.struts2.json.JSONException: org.apache.struts2.json.JSONException: org.apache.struts2.json.JSONException: java.lang.reflect.InvocationTargetException
解决方法1:
在Action里面注入spring时,只能生成set(),而不能有get()
如:
action里面调用 private UserService userService; 生成getXX()、setXX()后,请删掉getXX(),问题就解决了
解决方法2:
把action中的getXX()方法上面加上@JSON(serialize=false) 禁止序列化
浙公网安备 33010602011771号