pabsttheater / pabstetix

Issue Tracking for pabsttheater.org
0 stars 0 forks source link

Event date fields should force cache refresh #11

Closed sarandi closed 5 years ago

sarandi commented 6 years ago

From 20171128 email to Daniel (and Aaron): We've been noticing that in general, when we update date-related event content, the cache does not immediately deliver the correct newly updated content - we have to clear the cache manually. I don't know if there's a cache time offset that we're not waiting for, but in any case it should update immediately.

Use case: we accidentally announced a show, so I set the announce time back, but the update didn't refresh the cache last update, so it still appeared on the site.

sarandi commented 6 years ago

Below are header responses showing that the rhppabst17.staging isn't using caching - and if somehow it is, it's not being implemented in the same way as production. As a result, the above still holds true - production needs a manual cache flush via WP backend in order to update.

Header responses from Live Production Server: Sarandis-MacBook-Pro:~ sklikizos$ curl -I http://pabsttheater.org/events/ HTTP/1.1 200 OK Server: nginx Date: Thu, 07 Dec 2017 04:05:30 GMT Content-Type: text/html; charset=UTF-8 Connection: keep-alive Keep-Alive: timeout=20 Expires: Thu, 19 Nov 1981 08:52:00 GMT Pragma: no-cache Link: http://pabsttheater.org/wp-json/; rel="https://api.w.org/" X-TEC-API-VERSION: v1 X-TEC-API-ROOT: http://pabsttheater.org/wp-json/tribe/events/v1/ X-TEC-API-ORIGIN: http://pabsttheater.org WPE-Backend: apache X-Cacheable: SHORT Vary: Accept-Encoding,Cookie Cache-Control: max-age=600, must-revalidate X-Cache: HIT: 34 X-Pass-Why: X-Cache-Group: normal X-Type: default

Header responses from http://rhppabst17.staging.wpengine.com : Sarandis-MacBook-Pro:~ sklikizos$ curl -I http://rhppabst17.staging.wpengine.com/event/ HTTP/1.1 200 OK Server: nginx Date: Thu, 07 Dec 2017 04:09:48 GMT Content-Type: text/html; charset=UTF-8 Connection: keep-alive Keep-Alive: timeout=20 Set-Cookie: PHPSESSID=fd979215d3d5b86c9737f181ee84cdaa; path=/ Expires: Thu, 19 Nov 1981 08:52:00 GMT Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0 Pragma: no-cache Link: http://rhppabst17.staging.wpengine.com/wp-json/; rel="https://api.w.org/" X-TEC-API-VERSION: v1 X-TEC-API-ROOT: http://rhppabst17.staging.wpengine.com/wp-json/tribe/events/v1/ X-TEC-API-ORIGIN: http://rhppabst17.staging.wpengine.com WPE-Backend: apache

sarandi commented 6 years ago

curl -I http://rhppabst17stge.wpengine.com/event HTTP/1.1 301 Moved Permanently Server: nginx Date: Wed, 20 Dec 2017 15:45:08 GMT Content-Type: text/html; charset=UTF-8 Content-Length: 0 Connection: keep-alive Keep-Alive: timeout=20 Expires: Thu, 19 Nov 1981 08:52:00 GMT Pragma: no-cache Location: http://rhppabst17stge.wpengine.com/event/ WPE-Backend: apache X-Cacheable: non200 Cache-Control: max-age=600, must-revalidate Accept-Ranges: bytes X-Cache: HIT: 1 X-Pass-Why: X-Cache-Group: normal X-Type: default

sarandi commented 6 years ago

This bug is still live in production. Definitely caching related.

sarandi commented 6 years ago

22 is likely related, possibly the same or very similar problem.

etix-aaron commented 5 years ago

This item has been corrected with caching plugin update. Recommend closing.