On Jul 18, 2008, at 5:56 AM, Stephan Koops wrote:
>
> sorry, you misunderstood me; perhaps I wrote not clear enough.
> It was meant for a message body READER. Must the InputStream (given
> to the message body reader by the runtime) reaches its end, if the
> length is reached, or must every provider check the length from the
> content-length header and stop itself.
> If the runtime environment gives only an InputStream with the length
> the provider should read, than the message body readers are easier
> to implement and could be used to read "multipart/whatever" data.
> Then the multipart provider only must ensure, that the InputStream
> given to the readers for every part closes, if the length of the
> content of this part is reached.
>
Seems a little heavyweight to me.
Marc.
>
> Marc Hadley schrieb:
>> The spec/javadoc currently says that entity providers shouldn't
>> close the stream, I don't think it needs to say anything more ?
>>
>> Marc.
>>
>> On Jul 17, 2008, at 12:28 PM, Bill Burke wrote:
>>> I think the JAX-RS runtime implementation should be closing the
>>> stream. YOu can't implement multipart provider very well if the
>>> stream is closed , as you said.
>>>
>>> Stephan Koops wrote:
>>>> Hi,
>>>> is it the responsibility of an entity provider, to check the
>>>> length of the entity, or must the runtime environment must close
>>>> the stream? This could be interesting if someone wants to read a
>>>> "mutlipart/whatever" entity.
>>>> best regards
>>>> Stephan
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe_at_jsr311.dev.java.net
> For additional commands, e-mail: dev-help_at_jsr311.dev.java.net
>
---
Marc Hadley <marc.hadley at sun.com>
CTO Office, Sun Microsystems.