[jax-rs-spec users] [jsr339-experts] Re: Re: Modifying headers from ReaderInterceptor

From: Bill Burke <>
Date: Thu, 20 Sep 2012 12:00:18 -0400

On 9/20/2012 10:51 AM, Sergey Beryozkin wrote:
> On 20/09/12 15:45, Bill Burke wrote:
>> On 9/20/2012 10:15 AM, Santiago Pericas-Geertsen wrote:
>>> On Sep 20, 2012, at 6:17 AM, Sergey Beryozkin wrote:
>>>> If MessageBodyReaders had the same capability to modify the input
>>>> headers, then it would cause some minor issues I'm referring to below.
>>>> Reader interceptors are effectively higher-level MBRs. IMHO that is
>>>> another reason why they should not be able to modify the headers
>>> Off top of my head I can't think of any UC for which having writable
>>> headers in the reader context would be useful.
>> Keep it mutable, IMO. I can see wanting to change the content-type (add
>> a charset or something) or adding other headers that might trigger
>> behavior in the MBR.
> Why this can not be done at the filter level ?
> What do you think of the concerns I had in the original email ?
> I mean, we can just say, whatever, won't really harm to be able to
> update the headers from different chains, but it's a duplication, having
> two options to do the same thing, it seems to me it is

I don't care that much. Whatever u guys decide is ok with me.

Bill Burke
JBoss, a division of Red Hat