Over a million developers have joined DZone.
Platinum Partner

RESTEasy Wishlist

· Java Zone

The Java Zone is brought to you in partnership with ZeroTurnaround. Discover how you can skip the build and redeploy process by using JRebel by ZeroTurnaround.

Here are some stuff that I've been working on with RESTEasy. I simply don't have enough free time to spend on all of these. I'm hoping that this list will serve as a reminder about the important things I'm working on. I'm also hoping that this will serve as a method of other developers joining in the efforts to build some interesting functionality. Some of this functionality will simply come down to additional documentation of existing features.

  1. Pluggable annotation handling

    1. Pluggable method parameter annotation handling - Allow users to plug in their own behavior via annotations - for example, accessing session attributes or classing Servlet requestParameter (form/query parameter abstraction). Allow users to plug in their own annotations for existing behavior (such as Spring MVC annotations).
    2. Pluggable method and class handling - Allow additional handling of method finding. Allow additional annotation based post response construction processing (for example, 404 status instead of 204, additional cache header capabilities)
  2. Security - this is a common need of REST frameworks. There are solutions, but there needs to be a lot more before we're "there."

  3. Input Validation - this is a common feature of MVC frameworks. REST frameworks should have them as well. I know that Restlet has some kind of integration. I was also able to cobble together hibernate-validator with RESTEasy using Spring AoP. There should be an easier way to do that.

    The biggest issue here, IMHO, is defining requirements. Which status should be returned for which type of invalid input? URL parameters validation errors might return 404 (Not Found) while query/form parameter errors might return 400 (Bad Request). What should the body of the result message look like? HTML? JSon/XML? There are quite a few questions here, and no really "standard" yet that I've seen. IMHO, REST validation requires standardization

  4. Tighter integration with marshalling frameworks - Deep integration between RESTEasy/JAX-RS and the XML/JSon/YAML marshalling framework.

    1. Reusing Converter frameworks - Marshalling converters and Controller converters have a lot in common. They both need to take Strings and convter them to objects (or vice versa). Give the end user (the REST programmer) a consistent interface (API) for both body (un)marshalling and header (un)marshalling.
    2. HATEOAS - representing relationships and future actiosn as <link href=".." rel=".." > or something similar. I had some ideas, and apparently, Marc Headly, the JAX-RS spec co-lead, is working on HATEAOS as well.
    3. Context based marshalling - for example, in some resoures you want an object to be fully marshalled, and in others you want to expose only some information. Allow a user to do that in a declarative manner.
    4. Client-side Proxy based Lazy Loading - the client side should use <link href=".." rel=".." >'s to GET the next "application state". Allow simple ORM like lazy loading. This requires some deep integration between RESTEasy and a marshalling framework.
  5. RESTEasy Client: The Next Generation - The RESTEasy client is pretty cool already, but there are some ideas to make it even cooler.

    1. Client-side Proxy based Lazy Loading - this heavily depends on tighter integration with the marshalling framework.
    2. Annotation base Responses - Right now, there's a class structure for responses.
    3. Pluggable annotations - Custom annotations should be simple. Why not use Spring MVC's annotations here as well?
    4. Asynchronous clients - Ning has it... I want it (and the Jersey team is working on it... see the comments on the Ning link). Keep a comet connection open, and stream in data. Perhaps wrap Ning's client in RESTEasy somehow.
  6. Pluggable Metadata handling - JAX-RS and other metadata, such as validation annotations, Spring bean definitions and custom annotations, are pretty useful. Sure, you can map HTTP requests to methods with JAX-RS annotations, but you can do so much more with them. RESTEasy already allows you to generate. What this will give:

    1. Management consoles
    2. Auto-generated JavaScript APIs
    3. Auto-generated Test pages
  7. Pluggable cross system behavior - RESTEasy is very pluggable right now. You can do some pretty neat tricks with it... Hopefully, they're documented enough. There's always additional room for improvement. This would be features like:

    1. Customized exception handling
    2. Customized handling of "Not Found" scenarios
  8. Package Refactoring - the resteasy-jaxrs project got big. It's probably time to take out the client into resteasy-client. There are probably some other changes as well, although doing things like may break backwards compatibility, if it's not done carefully... I'm sure that Bill Burke has done this kind of thing before :).

There are definitely plenty of items that I forget... so much to do, and so little time. I definitely can't do all this myself... I hope I can "marsall" some assistance. I also need to have some conversations with REST experts on these items... I really should go to the WS-REST convention that's taking place this month. I should also use my recent promotion to Principal to further the OSS culture at SunGard Consulting.


From http://www.jroller.com/Solomon/entry/resteasy_wishlist1

The Java Zone is brought to you in partnership with ZeroTurnaround. Discover how you can skip the build and redeploy process by using JRebel by ZeroTurnaround.


{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}