users@jersey.java.net

Re: [Jersey] sideline caching via _at_Provider?

From: Paul Sandoz <Paul.Sandoz_at_Sun.COM>
Date: Fri, 20 Feb 2009 09:40:00 +0100

Hi Bill,

On Feb 19, 2009, at 10:59 PM, Bill de hOra wrote:

> Hi,
>
> I introduced a sideline cache (memcached) recently into some Jersey
> code backed by Spring. To avoid polluting the resource controller
> with if-in-cache checks, I used Spring AOP's @Around aspect to
> introduce the caching support.
>

Very nice.


> It occurred to me that a @Provider style approach would be nice for
> those not using Spring. So I was wondering if anyone here had done
> any caching work using Providers or custom annotations?
>

I do not know of any, but the same sort of idea occurred to me with
the recent feature i added for resource filtering:

   https://jersey.dev.java.net/source/browse/*checkout*/jersey/tags/jersey-1.0.2/api/jersey/com/sun/jersey/api/container/filter/package-summary.html

   http://blogs.sun.com/sandoz/entry/jersey_1_0_2_is

Would you be interested in working together and contributing something?


A while back, for some fun, i experimented doing something in Scala
with partial functions:

   http://blogs.sun.com/sandoz/entry/using_scala_s_closures_with

Paul.