Questions tagged [http-status-code-304]

The HTTP response status code 304 Not Modified

Indicates the resource has not been modified since last requested. Typically, the HTTP client provides a header like the If-Modified-Since header to provide a time against which to compare. Using this saves bandwidth and reprocessing on both the server and client, as only the header data must be sent and received in comparison to the entirety of the page being re-processed by the server, then sent again using more bandwidth of the server and client.

Related tags

See also RFC2616.

181 questions
11
votes
1 answer

304: The condition specified using HTTP conditional header(s) is not met

I'm currently storing files within Azure Blob Storage and when I request the files I get an message in firebug of 304 “The condition specified using HTTP conditional header(s) is not met” I've looked at Azure Blob: "The condition specified using…
Steve
  • 251
  • 4
  • 10
11
votes
1 answer

Avoiding 304 (not modified) responses

Is it an ExpiresDefault Apache directive enough to avoid HTTP Status 304 responses from the server? I have set ExpiresDefault "access plus 10 years" but I'm still seeing log entries with a 304 response for "GET…
That Brazilian Guy
  • 3,328
  • 5
  • 31
  • 49
11
votes
1 answer

Leveraging etags and chunked encoding at the same time?

updated question How can my application leverage etags, and does introducing streaming/chunked encoding introduce any complications? original question When doing HTTP streaming with Transfer-Encoding: chunked, Content-Length can't be sent because…
John Bachir
  • 22,495
  • 29
  • 154
  • 227
10
votes
2 answers

How does Rails know when to respond with 304 status?

Given I have rails controller which accesses DB to retrieve data and render JSON response using serializer, what conditions must be met to make rails respond with 304? If it has to compare previous response to currently retrieved, what kind of…
antiplayer
  • 323
  • 7
  • 15
10
votes
3 answers

Flask - Getting a 304 status for my external .css file

I'm building a web app. All the external links worked in my Project directory worked fine before but I noticed that yesterday every time I modify the .css file it didn't render this change at all. It actually is freezed with the same style…
tadm123
  • 8,294
  • 7
  • 28
  • 44
10
votes
2 answers

Why does the 304 status code count as a "redirect?"

I am currently trying to understand how exactly 304/Not modified qualifies for the 3xx-range class of HTTP status codes. RFC 1945, sec. 9.3 and RFC 2616, sec. 10.3 both read: This class of status code indicates that further action needs to be taken…
DaSourcerer
  • 6,288
  • 5
  • 32
  • 55
10
votes
1 answer

IE9 fakes 304 after receiving ETag

I've got a problem with AJAX & Internet Explorer 9: it stops polling our server after receiving response to initial etagged GET. It pretends to issue requests with response like "Response HTTP/1.1 304 Not Modified, Status 200 OK" (yes, two different…
9
votes
2 answers

Angularjs application not handling 304 responses when retrieving html templates from firebase hosting server

I have some users not being able to access some templates on my angularjs application when my server responds with status code 304. Angularjs is logging [$compile:tpload] as you can see bellow and the views are not being shown to the users. So…
9
votes
2 answers

Are browsers supposed to handle 304 responses automagically?

Might be a silly question, but I haven't found any clear answer yet. My server handles ETag caching for some quite big JSON responses we have, returning 304 NOT MODIFIED with an empty body if the If-None-Match header contains the same hash as the…
sp00m
  • 47,968
  • 31
  • 142
  • 252
9
votes
1 answer

How to prevent HTTP 304 in Django test server

I have a couple of projects in Django and alternate between one and another every now and then. All of them have a /media/ path, which is served by django.views.static.serve, and they all have a /media/css/base.css file. The problem is, whenever I…
augustomen
  • 8,977
  • 3
  • 43
  • 63
8
votes
1 answer

Is ETag returned in a 304 response?

I'm building a node.js app which - reguarly, once a day - fetches data from some external web server (using "request" package). I want to avoid fetching same data twice, so I keep track of each resource ETag when first downloading (200 status…
MarcoS
  • 17,323
  • 24
  • 96
  • 174
8
votes
1 answer

Volley exception error when response code 304 and 200

Playing around with the Volley library, I noticed that when making a POST JsonObjectRequest , if the server returns a code 304 or 200 with no data in the response (response.data), Volley interprets it as an error response, instead of a success. I…
Miguel
  • 1,184
  • 1
  • 11
  • 13
7
votes
2 answers

Jquery.get() not working in IE8/9. Won't load cached pages 304 not modified

Code Igniter version '2.0.3' Jquery 1.7 Jquery History plugin I have a CodeIgniter app that I've built in an ajax fashion. I have a function as follows: $(document).on('click','.ajax_link',function(e){ //Stop the normal href action …
7
votes
1 answer

Recognize HTTP 304 in service worker / fetch()

I build a service worker which always responds with data from the cache and then, in the background, sends a request to the server. If the server responds with HTTP 304 - not modified everything is fine, if the server responds with HTTP 200, that…
6
votes
5 answers

Cache-Control not returning 304

I have a website with static assets that don't change (js, images, etc). Each of these assets has the cache-control header set with the following property: cache-control: public, max-age=31536000, immutable However, when I reload the page I'm still…
tomciopp
  • 2,602
  • 2
  • 31
  • 60
1
2
3
12 13