Installation#
Caching support is implemented by the package plone.app.caching
.
It is already installed as a dependency of the Plone package.
It should be available on all Plone installations.
Even though cache support is available in Plone, it is not enabled by default. It is highly recommended to configure caching for every new Plone site in production.
Import a caching profile#
Importing a caching profile is currently only supported in the Classic UI.
We recommend that you import a caching profile to start. You can always modify the profile later as needed.
As an administrator, navigate to Site Setup. Under the Advanced heading or navigation item, select the Caching control panel.
From here click either the helpful link in the blue information box importing a preconfigured set of caching rules or the Import settings tab. You will see the Import caching profiles control panel.
Select options that are appropriate for your caching environment.
- With caching proxy
Settings useful for setups with a caching proxy such as Varnish or a CDN
- Without caching proxy
Settings useful for setups without a caching proxy such as Varnish or a CDN
- Take a snapshot of the site prior to importing new setting.
This allows rollback to a previous state via the
portal_setup
tool.
Enable caching#
Enabling of caching is currently only supported in the Classic UI.
As an administrator, navigate to Site Setup. Under the Advanced heading or navigation item, select the Caching control panel.
In the Caching control panel, the tab Change settings is selected by default. Inside of it, the tab Global settings has the option to Enable caching. This setting is disabled by default.
To enable caching, click the checkbox, and click the Save button.
Troubleshooting#
When the caching control panel is not there, there can be various reasons for this:
If your installation does not load the
Plone
package, but onlyProducts.CMFPlone
, thenplone.app.caching
is not included.If the package is included, but you add a Plone Site using the advanced form and disable caching, then the control panel is not there.
If you want to install it in an existing Plone Site:
Make sure the package is available in the Plone instance by adding
plone.app.caching
orPlone
to your installation.From the Plone Site Setup, under the Advanced heading or navigation item, select the Management Interface control panel.
Click portal_setup, and then click the Import tab.
Select the profile by title HTTP caching support, or by id profile-plone.app.caching:default.
Select Apply new profiles. Run upgrade steps for already applied profiles. Recommended..
Click the Import all steps button.