Skip to main content
Run cache warmers after a fresh deployment or restart to ensure the first real visitors don’t experience slow load times while the IIIF server processes images on demand.

cache mirador

Pre-warm the Mirador IIIF viewer cache for paged content items. When the IIIF server has not yet cached a paged item’s child images, the first visitor to that page experiences slow load times while the server processes the images. This command fetches a list of paged content URLs from either a JSON endpoint or a file, reads the Mirador settings embedded in each page’s Drupal settings JSON, and warms the related IIIF resources before real visitors arrive. Pass exactly one of: --endpoint JSON endpoint returning URL objects --url-file text file with one URL per line

When to run it

Run cache mirador after:
  • Deploying a new version of your Islandora site.
  • Restarting the IIIF server.
  • Ingesting a large batch of new paged content.
The command no longer uses a browser. It fetches each page directly, extracts the embedded drupal-settings-json, reads the Mirador manifest ID, then warms selected IIIF URLs from the manifest. Pass exactly one input source:
  • --endpoint for a paginated JSON feed of URL objects.
  • --url-file for a plain text file with one URL per line.

Warm modes

Use --mode to choose what gets warmed from each manifest:
  • ttfb default: the first full image URL and the first 10 thumbnails.
  • browse: every full image URL after the first, plus thumbnails starting at 11 if present.
  • full: the first full image URL, all thumbnails, and every remaining full image URL.

Resume behavior

Progress is saved under ~/.sitectl as URLs complete, so canceling a long run does not force a full restart next time.
  • Normal reruns resume automatically.
  • --restart discards saved progress and starts over.

Request pacing

Use --delay to control how long the command sleeps between HTTP warm requests. The default is 1s.