users@jersey.java.net

Re: [Jersey] Invalidating cache

From: Paul Sandoz <Paul.Sandoz_at_Sun.COM>
Date: Thu, 09 Jul 2009 11:46:33 +0200

On Jul 6, 2009, at 10:39 AM, Nabil Benothman wrote:

>
> Hi envery one,
> can some one help me about how to invalidate cache with jersey when
> i modify
> some entity

You can send a response with an instance of CacheControl:

https://jsr311.dev.java.net/nonav/javadoc/javax/ws/rs/core/CacheControl.html

IIUC if you are using Last-Modified and ETag in responses and any
updates to those headers because the entity was updated should update
the cache.

Paul.