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.Documentation Index
Fetch the complete documentation index at: https://sitectl.libops.io/llms.txt
Use this file to discover all available pages before exploring further.
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.| Flag | Default | Description |
|---|---|---|
--endpoint | JSON endpoint returning an array of objects with a url field. Mutually exclusive with --url-file. | |
--url-file | Path to a file containing one URL per line. Mutually exclusive with --endpoint. | |
--mode | ttfb | Mirador warm mode: ttfb, browse, or full. |
--limit | 0 | Maximum number of URLs to warm. Use 0 for all URLs from the selected source. |
--workers | 1 | Number of concurrent warm workers. |
--delay | 1s | How long to sleep between HTTP warm requests. |
--restart | false | Discard saved progress and restart from the beginning. |
When to run it
Runcache mirador after:
- Deploying a new version of your Islandora site.
- Restarting the IIIF server.
- Ingesting a large batch of new paged content.
drupal-settings-json, reads the Mirador manifest ID, then warms selected IIIF URLs from the manifest.
Pass exactly one input source:
--endpointfor a paginated JSON feed of URL objects.--url-filefor a plain text file with one URL per line.
Warm modes
Use--mode to choose what gets warmed from each manifest:
ttfbdefault: 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.
--restartdiscards saved progress and starts over.
Request pacing
Use--delay to control how long the command sleeps between HTTP warm requests. The default is 1s.
