You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@struts.apache.org by "James Holmes (JIRA)" <ji...@apache.org> on 2008/05/28 16:08:06 UTC
[jira] Updated: (WW-2358) RestWorkflowInterceptor in
struts2-rest-plugin is returning a status which kills browser sessions
[ https://issues.apache.org/struts/browse/WW-2358?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
James Holmes updated WW-2358:
-----------------------------
Fix Version/s: (was: Future)
2.1.3
In my opinion this needs to be resolved as part of the 2.1.x release cycle as that's where we're introducing the REST plugin.
> RestWorkflowInterceptor in struts2-rest-plugin is returning a status which kills browser sessions
> -------------------------------------------------------------------------------------------------
>
> Key: WW-2358
> URL: https://issues.apache.org/struts/browse/WW-2358
> Project: Struts 2
> Issue Type: Bug
> Components: Other
> Affects Versions: 2.1.1
> Environment: Struts 2.1.1-SNAPSHOT on Jetty 6.1.6
> Reporter: Sarat Pediredla
> Fix For: 2.1.3
>
> Attachments: WW-2358.patch
>
>
> The RestWorkflowInterceptor in the struts2-rest-plugin is a cool addition but unfortunately returns SC_BAD_REQUEST on validation fail, which might work with testing frameworks but kills real browsers.
> The response tested on Safari 3 and Firefox 2.0.0.11 just shows a blank screen.
> If I change the following line from,
> HttpHeaders info = new DefaultHttpHeaders()
> .disableCaching()
> .renderResult(method)
> .withStatus(SC_BAD_REQUEST);
>
> to,
> HttpHeaders info = new DefaultHttpHeaders()
> .disableCaching()
> .renderResult(method);
> then it works great as the server returns the right result as of validation failure (editNew in this case)
> I am not entirely sure what the solution to this would be; either using a status code that the browsers will respond to or maybe not have a status code at all (although this might not be strictly RESTful) given that errors are sent back in a Map.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.