Skip to content
Grav 2.0 is officially stable. Read the announcement →
Archive

Cache Initialization

Started by Muut Archive 11 years ago · 3 replies · 370 views
11 years ago

Hi,

I'm playing with grav for the first time. Attempted to port an existing blog with 2898 entries, generating item.md files, placing them in grav/user/pages/01.blog/X/ folders, using the Blog Site skeleton on my MacBook Air. The front page loads, but an individual page gives an error:

TXT
                Maximum execution time of 30 seconds exceeded

Seems to hang on this code:

PHP
                // compute score of content to content matches
                if ($config['content_match']['process']) {
                    similar_text($page->content(), $item->content(), $score);
                    $content_matches[$item->path()] = intval($score);
                }

Is there a cache initialization task I need to do first?

Thanks.

11 years ago

We've only really tested Grav up to about a 1000 pages, so your in a bit of uncharted waters with your blog size. The first thing I would recommend is to turn of the page checking to ensure that every page is not checked for modifications on every load. It will mean you will have to manually clear the cache if there is a new page added or modification made. You can do this by editing your user/config/system.yaml file and changing the page check method:

YAML
pages:
  check:
    method: none

That should help things out. After that, if it still hangs, can you please provide the FIle name, and line number of the code you have pasted above? And we can look a little deeper.

Thanks

11 years ago

Thanks for the suggestion. I tried both of these settings (pages: check: method: and cache: check: method: - which was there before) and still got the error.

…/­user/­plugins/­relatedpages/­relatedpages.php177

11 years ago

Maybe turn off the related pages plugin for now. You can just uninstall it with gpm (you can install it again later if needed).

BASH
bin/gpm uninstall relatedpages

Can you also paste your current system.yaml file between triple ticks (or put up a gist)

Suggested topics

Topic Participants Replies Views Activity
Archive · by Deleted User, 9 years ago
0 1322 9 years ago
Archive · by Muut Archive, 9 years ago
2 917 9 years ago
Archive · by Muut Archive, 9 years ago
2 4048 9 years ago
Archive · by Muut Archive, 9 years ago
1 2922 9 years ago
Archive · by Muut Archive, 9 years ago
3 1106 9 years ago