I'm betting on the difference between your own timezone (in Etag) and GMT (in Last-Modified) ...
Moises
On Apr 7, 2010, at 4:47 PM, Rob Koberg wrote:
> (I am using Jersey 1.1.5.1)
>
> Why does the following produce different dates for the Last-Modified
> and ETag headers:
>
> Date lastMod = new Date(file.lastModified());
> return Response.ok(file)
> .tag(DateFormat.getDateInstance(DateFormat.FULL).format(lastMod))
> .lastModified(lastMod)
> .build();
>
> Firebug is showing the following in the headers:
>
> Etag "Wednesday, February 16, 2005"
> Last-Modified Thu, 17 Feb 2005 04:25:14 GMT