Uploaded image for project: 'SimplyE 2.0'
  1. SimplyE 2.0
  2. SIMPLY-2581

Set Cache-Control header for a cached feed proportionally to the in-database cache time

XMLWordPrintable

      I discovered this problem while working on https://jira.nypl.org/browse/SIMPLY-2532.

      We can get very sophisticated when deciding how long we'll cache a feed in the "cachedfeeds" table. But when it comes to setting the Cache-Control header, which tells clients and intermediaries how long to cache that feed, we basically always say "10 minutes".

      It should be possible to use the "cachedfeeds" value to derive the Cache-Control header. However since the feed is passed back from CachedFeed.fetch as a Unicode string, this would probably require creating a subclass of "unicode" that has caching information.

            leonardrichardson Leonard Richardson [X] (Inactive)
            leonardrichardson Leonard Richardson [X] (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: