AEM调度程序缓存规则



我想添加一个缓存规则,该规则使用给定的网址/路径缓存多个扩展名。

样本:

/rules
/0100
{
/url "/urlpath/*"
/type "allow"
/extension '(json|xml|html|clientlibs|css|gif|ico|js|png|swf|jpe?g|woff2?)'
}

这有效吗?

必须遵循指定要缓存的文档的要求:

/rules 属性中的每个项都包含一个 glob 模式和一个类型:

The glob pattern is used to match the path of the document.
The type indicates whether to cache the documents that match the glob pattern. 
The value can be either allow (to cache the document) or
deny (to always render the document).

看起来您正在尝试在缓存部分中使用过滤规则的语法。 我认为您需要使用与通配符的 URL 和扩展名匹配的 glob 模式,因此您可能需要使用多个规则。

最新更新