Springmvc Framework, if you use Ajax to request a method back to the table if using @responsebody returns a Boolean value, Ajax can not get any callback data.
However, if a string type is returned, it is normal.
Test the code to write without any problems, nor error. Just enter the URL of the AJAX request directly in the address bar will be reported 404.
The resource identified by this request is a capable of generating responses with characteristics not acceptable accord ing to the request "accept" headers ().
After confirming that there is no problem with the code, the problem is locked in the @responsebody annotation, which automatically encapsulates the return value.
Various methods have been tried, such as adding a. json suffix after the URL, importing various jakson packages, and so on.
The key question is whether the jar package is missing, and then the suspect jar package is imported into the experiment, or it is unsuccessful.
Finally, one of the other articles on the web was inspired, and the next spring version was upgraded. It worked!
It seems that later encountered this, the code is not a problem, the function of the problem, and the information on the Web less than the case. Priority should be given to the upgrade version.
It may be that this new feature is used by very few people.
I think as a mature coder, the first thing to focus on is the version number of your environment ...
SPRINGMVC Ajax Request method, @Responsebody if the return is a Boolean value, Ajax will not receive any callback data