Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

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

未关闭
#15,623 0 条评论 2 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 1 天内回复

还没有人认领这个 Issue。

评估

难度
4/5
预计耗时
3-5 天
新手友好度
35/100
Issue 类型
缺陷
描述清晰度
基本清楚
活跃度
活跃
技术栈
aws, laravel, php

调研方向

Start in Statamic\Http\Controllers\CP\Utilities\CacheController::getImageCacheStats(), where the recursive listContents('', true) call walks the Glide cache disk to count files and sum sizes. Reproducing needs an S3-backed Glide cache with many generated presets, so there is no simple local test named in the issue. Done means the Cache page loads without a full synchronous traversal, with the maintainers' choice between caching, async computation or an opt-out settled first.

由索引模型根据 Issue 内容生成。

描述

utilities
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

主要语言
PHP
星标
4.9k
派生
647
平均合并
1 天 20 小时
30 天内合并 PR
113

环境准备

这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

statamic/cms 的其他 Issue

查看 statamic/cms 的全部 Issue

相似的 Issue

更多 PHP Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。