Uploaded image for project: 'eZ Publish / Platform'
  1. eZ Publish / Platform
  2. EZP-30755

HTTP cache not active on REST image variations when image added in earlier version

    XMLWordPrintable

    Details

      Description

      1. Create a content item with an image field, add the image in the first version.
      2. Edit and republish the item without modifying the image
      3. Query the content over REST (curl -v http://localhost:8000/api/ezp/v2/content/binary/images/54 -H 'Accept: application/vnd.ez.api.Content+xml
      4. Query twice a variation of that image over REST, using the URI found in the image field value in the response above (curl -v http://localhost:8000/api/ezp/v2/content/binary/images/54-194-1/variations/small
      5. On the second request, X-Cache will be a MISS, while we expect a HIT

      This is because of the image ID (54-194-1) in the variation request. 1 is the version number. The response is only cached if that version number (1) matches the current version number of the content item (2 with the procedure above). Removing that test fixes the issue.

        Attachments

          Activity

            People

            Assignee:
            Unassigned
            Reporter:
            bertrand.dunogier@ez.no Bertrand Dunogier
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated: