users@jax-rs-spec.java.net

[jax-rs-spec users] [jsr339-experts] Re: restrict Request.getEntityInputStream()?

From: Marek Potociar <marek.potociar_at_oracle.com>
Date: Tue, 13 Dec 2011 12:14:53 +0100

On 12/13/2011 01:47 AM, Bill Burke wrote:
> I don't not think Request.getEntityInputStream() should be allowed on the client side. An IllegalStateException should
> be thrown.

Why?

>
> Also on the client, RequestBuilder.entityInputStream should be equivalent to:
>
> RequestBuilder.entity(inputStream);
>
> or also throw an IllegalStateException

Makes me also wonder if we need the getEntityInputStream() method at all... Would Request.getEntity(InputStream.class)
be a viable replacement for both, server and client side?

Marek

>
> Bill
>