Skip to content

CP Cache Utility: Opening the cache manager times out when the Glide Cached Presets are too big #15623

Closed

Description

@HannesEURESA

Bug description

When opening the Control Panel’s Utilities → Cache page, the request can return a 504 Gateway Timeout.

The Glide cache is configured on an S3 disk. In Statamic\Http\Controllers\CP\Utilities\CacheController::getImageCacheStats(), the cache manager recursively lists the Glide cache contents with listContents('', true) and calculates the file count and total size. This appears to make the page load increasingly expensive as the number of cached images grows.
We have currently 99,636 generated Presets

Observed: 504 at 2026-10-09 06:43:35 GMT; Cloudflare Ray ID: a47b66eb8dd3a9-FRA

How to reproduce

Configure the Glide cache to use an S3-backed disk.
Populate the cache with a large number of generated images.
Open Control Panel → Utilities → Cache.
Actual result: The request GET /cp/traumurlab/utilities/cache returns 504 Gateway Timeout.

Expected result: The cache manager loads without requiring a full synchronous traversal of the remote image cache on every page visit.

Could the Glide cache statistics be cached, computed asynchronously, or made optional? Is there a recommended configuration for using the cache manager with a remote S3 disk?

Logs

Environment

Environment
Laravel Version: 13.34.0
PHP Version: 8.5.8
Composer Version: 2.10.2

Timezone: Europe/Berlin
Locale: de

Locales
Installed: cs, da, de, en, nb, nl, nn
LaravelLang\Lang\Plugin: 15.37.3
Locales Version: 2.11.0
Protected: de, en
Publisher Version: 16.8.0

Livewire
Livewire: v4.4.7

Statamic
Version: 6.34.1 PRO

Statamic Eloquent Driver
Addon Settings: file
Asset Containers: file
Assets: file
Blueprints: file
Collection Trees: eloquent
Collections: eloquent
Entries: eloquent
Fieldsets: file
Form Submissions: eloquent
Forms: eloquent
Global Sets: eloquent
Global Variables: eloquent
Navigation Trees: eloquent
Navigations: eloquent
Revisions: eloquent
Sites: file
Taxonomies: eloquent
Terms: eloquent
Tokens: file

S3-backed Glide cache.

Installation

Fresh statamic/statamic site via CLI

Additional details

No response

Activity

  1. changed the title [-][CP Cache Utility] Opening the cache manager times out when the Glide Cached Presets are too big[/-] [+]CP Cache Utility: Opening the cache manager times out when the Glide Cached Presets are too big[/+] on Oct 9, 2026
  2. HannesEURESA commented on Oct 30, 2026

    @HannesEURESA
    Author

    Thanks, now we can reach the Cache Manager, but after a short time the request GET /cp/traumurlab/utilities/cache returns 504 Gateway Timeout again.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions