statamic / cms

The core Laravel CMS Composer package
https://statamic.com
Other
3.59k stars 492 forks source link

Static cache being cleared #10167

Closed tomhayes closed 4 weeks ago

tomhayes commented 1 month ago

Bug description

I've set the static cache up to never be invalidated, like so in config/static-caching.php:

    'invalidation' => [

        'class' => null,

        'rules' => [],

    ],

However, when I prewarm the cache, it seems to build for a while and then get cleared, restarting from 0.

How to reproduce

Set invalidations rules as above prewarm static cache Watch as the cache reached about 200 files, then restarts from 0.

Logs

No response

Environment

Environment
Application Name: Redacted
Laravel Version: 10.48.10
PHP Version: 8.2.10
Composer Version: 2.7.2
Environment: local
Debug Mode: ENABLED
URL: redacted.co.uk
Maintenance Mode: OFF

Cache
Config: CACHED
Events: CACHED
Routes: CACHED
Views: CACHED

Drivers
Broadcasting: log
Cache: redis
Database: mysql
Logs: stack / single
Mail: smtp
Queue: database
Session: redis

Livewire
Livewire: v3.4.12

Statamic
Addons: 10
Sites: 1
Stache Watcher: Disabled
Static Caching: full
Version: 5.1.0 PRO

Statamic Addons
duncanmcclean/static-cache-manager: 4.0.0
jacksleight/statamic-bard-mutator: 2.3.1
jonassiewertsen/statamic-livewire: 3.3.1
statamic-rad-pack/runway: 7.0.0
statamic/eloquent-driver: 4.0.0
stillat/relationships: 2.2.0
studio1902/statamic-peak-browser-appearance: 3.4.0
studio1902/statamic-peak-commands: 4.4.0
studio1902/statamic-peak-seo: 8.13.1
studio1902/statamic-peak-tools: 4.4.2

Statamic Eloquent Driver
Asset Containers: file
Assets: eloquent
Blueprints: file
Collection Trees: file
Collections: file
Entries: eloquent
Forms: file
Global Sets: file
Global Variables: file
Navigation Trees: file
Navigations: file
Revisions: file
Taxonomies: file
Terms: eloquent

Installation

Starter Kit using via CLI

Additional details

No response

duncanmcclean commented 1 month ago

Watch as the cache reached about 200 files, then restarts from 0.

Just to clarify, you're running php please static:warm, it warms 200 URLs, then the URLs start from the beginning again?

When it starts warming the URLs again, is the static cache directory empty?

duncanmcclean commented 4 weeks ago

Since I'm not able to reproduce this issue myself and you haven't responded with additional info, I'm going to close this issue for the time being.

Let us know when you're still running into this issue and we can re-open. Thanks!