@Override protected ICacheEntryValidity computeValidity(final IEngineConfiguration configuration, final String ownerTemplate, final String template, final Map<String, Object> templateResolutionAttributes) { /* * This check is made so that we don't fill the cache with entries for the same * template with different jsessionid values. */ if (JSESSIONID_PATTERN.matcher(template.toLowerCase()).matches()) { return NonCacheableCacheEntryValidity.INSTANCE; } return super.computeValidity(configuration, ownerTemplate, template, templateResolutionAttributes); }
@Override protected ICacheEntryValidity computeValidity( final IEngineConfiguration configuration, final String ownerTemplate, final String template, final Map<String, Object> templateResolutionAttributes ) { if ( isDisableCache() ) { return new NonCacheableCacheEntryValidity(); } return super.computeValidity( configuration, ownerTemplate, template, templateResolutionAttributes ); }