I have a requirement to add the same HTTP header multiple times to a JAXRS response. For example, I need to add the HTTP header "Warning" to my JAXRS response multiple times for each error detected:
HTTP/1.1 200 OK Content-Type: application/json X-Total-Count: 1 Warning: BADSITE-2: failed to execute query due to this exception: blah blah Warning: BADSITE: failed to execute query due to this exception: more blah Date: Wed, 06 Jul 2011 13:55:06 GMT Content-Length: 436 Server: Jetty(7.4.2.v20110526) I have only been able to get the header to appear once. I have tried using Response.ResponseBuilder.header(...) multiple times for each occurrence of "Warning" header. I have also tried a single call to Response.ResponseBuilder.header( "Warning", <comma-delimited-list-of-warnings>) where each warning meessage's text is delimited by a comma. In both cases I only get a single Warning HTTP header in the response, either with the entire comma-delimited text in it or with the last warning's text loaded in the http header. Any help/suggestions would be appreciated. Thanks. -- View this message in context: http://cxf.547215.n5.nabble.com/Same-HTTP-header-in-JAXRS-response-multiple-times-tp4556926p4556926.html Sent from the cxf-user mailing list archive at Nabble.com.
