title: Servlet response ETag Cache
body: <p>I want to use ETag to cache the version of a request and return 304 not modifed response to the client so the client can use last cached page. </p>
  
  <p>So my url is like this which returns a json response </p>
  
  <pre><code>"http://server/WEB_GWT/prmCall?prmName=PRM_SIS_PROG_REG_STATUS"
  </code></pre>
  
  <p>In my servlet handling this request, I am always putting ETag information to store its value to be the version of url param <strong>PRM_SIS_PROG_REG_STATUS</strong>. 
  So response header returning to client is</p>
  
  <pre><code>HTTP/1.1 200 OK
  Date: Sat, 07 Dec 2013 16:07:49 GMT
  Server: IBM_HTTP_Server
  ETag: "5"
  Last-Modified: Sat, 07 Dec 2013 16:07:49 GMT
  Content-Length: 356
  Keep-Alive: timeout=10, max=99
  Connection: Keep-Alive
  Content-Type: application/json
  Content-Language: tr-TR
  </code></pre>
  
  <p>In my next request, I am expecting this request header to include "If-None-Match" header to return the version of the request but I cannot get this header param. Any idea why I cannot get my ETag back.</p>
  
  <p>My next request header is </p>
  
  <pre><code> GET /OZU_GWT/prmCall?prmName=PRM_SIS_PROG_REG_STATUS HTTP/1.1
  Host: 10.100.199.103
  Connection: keep-alive
  Cache-Control: max-age=0
  If-Modified-Since: Thu, 01 Jan 1970 00:00:00 GMT
  User-Agent: Mozilla/5.0 (Windows NT 6.2; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/31.0.1650.57 Safari/537.36
  Accept: */*
  Referer: http://10.100.199.103/OZU_GWT/
  Accept-Encoding: gzip,deflate,sdch
  Accept-Language: tr-TR,tr;q=0.8,en-US;q=0.6,en;q=0.4
  Cookie: JSESSIONID=0000kvocMBmjoWPbpKt_VAsDUMv:-1
  </code></pre>