Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

We've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

General Questions /

General questions about getting started with SilverStripe that don't fit in any of the categories above.

Moderators: martimiz, Sean, Ed, biapar, Willr, Ingo, swaiba

What's the state of caching/static Silverstripe sites?


Go to End


3 Posts   882 Views

Avatar
AshKyd

Community Member, 3 Posts

28 February 2015 at 8:11pm

Hi all. I'm looking at building a new site and I'm just wondering what's the status on caching or static site building with Silverstripe?

  1. Is there a decent resource/explainer on how to optimise a Silverstripe site for speed/performance. Particularly thinking of lower-traffic environments where there's not a constant stream of traffic to keep stuff in cache.
  2. I know there's the built-in caching, but how well does it perform, particularly in the situation described above? Is there an explainer on how it works in general?
  3. Is there a module or other way to build out a static or semi-static site from a Siverstripe backend?
  4. Putting something like nginx or CloudFlare in front makes sense, but how well does it perform out of the box and are there any performance gotchas or guidelines?

Avatar
martimiz

Forum Moderator, 1391 Posts

28 February 2015 at 11:52pm

If, by built-in caching, you're referring to the default SilverStripe cache, then that is basically how SilverStripe works by default, by combining templates, configuration and code in cache. So there is really nothing to gain there.

Then there is the also built-in frontend partial caching, where you can custom-cache selected template blocks. Read here: http://doc.silverstripe.org/en/developer_guides/performance/partial_caching. In many cases I've been able to reduce loading speeds by about 30% (others may have other figures), depending on the site structure and the willingness to keep some data stale for some amount of time.

As to static caching, there are some modules for that. The original Static Publisher now lives in its own module - http://addons.silverstripe.org/add-ons/silverstripe/staticpublisher. Also check out the Dynamiccache module - http://addons.silverstripe.org/add-ons/tractorcow/silverstripe-dynamiccache.

And then you can use combinations :)

Other reads:
- http://www.silverstripe.org/blog/improving-silverstripe-performance/
- http://www.silverstripe.org/blog/how-to-improve-website-performance/

As to point 4 - I'll have to leave that to others :)

Avatar
AshKyd

Community Member, 3 Posts

1 March 2015 at 3:08pm

Cheers, that's really useful. I'll do some reading. :)