Re: JSR311: Client API

From: Paul Sandoz <Paul.Sandoz_at_Sun.COM>
Date: Thu, 06 Mar 2008 17:12:25 +0100

Bill Burke wrote:
> I'm happy with Apache HttpClient and use it to test our jax-rs
> implementation. Its a little clunkier than what you're proposing, but a
> bit more mature and much more feature rich.

One of the reasons i created this API was i did not want to use the
clunky Apache HttpClient, or HttpURLConnection, for writing tests. So i
wrote something else for testing and the client API popped out of that.
RI unit tests make extensive use of the client API both for networked
and non-networked (in-memory transport) tests. I have found it to be
very productive for writing tests. I am currently using
HttpURLConnection as the underlying implementation but i could easily
use the Apache HttpClient to get more underlying functionality.

> For a client API I was thinking more of:
> Where you could re-use jax-rs annotations and providers on an interface
> to create a proxy. What we have implemented still needs some work, but
> you probably get the gist.

The key difference i see is this: the Jersey client API focuses on the
uniform interface constraint; and the RESTeasy client framework focuses
on service-specific Java artifacts.


| ? + ? = To question
    Paul Sandoz