Uploaded image for project: 'Struts 2'
  1. Struts 2
  2. WW-4545

Setting status code in HttpHeaders will be ignored

VotersWatch issueWatchersLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

    Details

      Description

      Setting the status code for validation has no effect.

      <constant name="struts.rest.validationFailureStatusCode" value="406"/>
      

      Inside of the RestWorkflowInterceptor this status code is used:

                  	HttpHeaders info = new DefaultHttpHeaders()
                  	    .disableCaching()
                  	    .renderResult(method)
                  	    .withStatus(validationFailureStatusCode);
      

      But the result has still a 200 success result.

        Attachments

        1. WW-4545.patch
          1 kB
          Johannes Geppert

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              jogep Johannes Geppert

              Dates

              • Created:
                Updated:
                Resolved:

                Issue deployment