Uploaded image for project: 'eZ Publish / Platform'
  1. eZ Publish / Platform
  2. EZP-21510

'Clear View cache from here' action ignores CacheThreshold setting, performance issues/db deadlocks

    Details

      Description

      Expiring view cache using the 'Delete view cache from here' menu option ignores the [ContentSettings],CacheThreshold setting.
      This can cause performance issues, and possibly even db deadlocks on sites with very large content trees and/or load.

      Steps to reproduce:
      • In site.ini, ContentSettings group, specify a low value for CacheThreshold (such as 25)
      • Enable kernel-content-edit condition in debug.ini
      • In the administration interface, click to view the root node; click class icon for the popup menu, and choose the 'Delete view cache from here' option.
      Result:

      The content objects will be cleared one by one, as can be verified in the debug log. sample:

      [ Sep 04 2013 20:01:50 ] [192.168.56.1] count in nodeList <kernel-content-edit>:
      2
      [ Sep 04 2013 20:01:50 ] [192.168.56.1] count in nodeList <kernel-content-edit>:
      2
      [ Sep 04 2013 20:01:50 ] [192.168.56.1] count in nodeList <kernel-content-edit>:
      3
      [ Sep 04 2013 20:01:50 ] [192.168.56.1] count in nodeList <kernel-content-edit>:
      2
      [ Sep 04 2013 20:01:50 ] [192.168.56.1] count in nodeList <kernel-content-edit>:
      2
      [ Sep 04 2013 20:01:50 ] [192.168.56.1] count in nodeList <kernel-content-edit>:
      5
      ... (repeated for the number of objects)
      

      Expected Result:

      The CacheThreshold should be met, and a 'global' expiry issued. sample debug:

      [ Sep 04 2013 20:02:37 ] [192.168.56.1] count in nodeList <kernel-content-edit>:
      2
      [ Sep 04 2013 20:02:38 ] [192.168.56.1] count in nodeList <kernel-content-edit>:
      44
      [ Sep 04 2013 20:02:38 ] [192.168.56.1] eZContentCacheManager::clearObjectViewCacheArray:
      Expiring all view cache since list of nodes(44) exceeds site.ini\[ContentSettings]\CacheThreshold
      

        Issue Links

          Activity

          Show
          André Rømcke added a comment - Merged in https://github.com/ezsystems/ezpublish-legacy/commit/23b55d9d6cbde1de538bdff1f0dd9d656dd2f7ab
          Hide
          Joao Pingo (Inactive) added a comment - - edited
          Show
          Joao Pingo (Inactive) added a comment - - edited Tested on Master, 5.2, 5.1, 5.0, 4.7, 4.6 and 4.5 with tc-2001 Master - Passed Note: Not able to reproduce original issue, lots of patch reverting is needed, sanity check was run and behaviour is correct eZPublish 5.2 - Passed eZPublish 5.1 - Passed eZPublish 5.0 - Passed Patch from https://jira.ez.no/browse/EZP-21509 is needed https://github.com/ezsystems/ezpublish-legacy-ee/commit/12b22f2dd805fee3876873123a55d585e2ed86bd eZPublish 4.7 - Passed Patch’s from https://jira.ez.no/browse/EZP-19544 are needed https://github.com/ezsystems/ezpublish-legacy-ee/commit/8809cc https://github.com/ezsystems/ezpublish-legacy-ee/commit/861fd9c Note: https://github.com/ezsystems/ezpublish-legacy-ee/commit/5f828f39.diff is alredy present in a 4.7 with SP, possibly this was already distributed? eZPublish 4.6 - Passed Patch’s from https://jira.ez.no/browse/EZP-19544 are needed https://github.com/ezsystems/ezpublish-ee/commit/7853f2aae659d0142188f9b78773ce08a07400ec https://github.com/ezsystems/ezpublish-ee/commit/f456fe6 https://github.com/ezsystems/ezpublish-ee/commit/c9b3e9898b89395e7fd83d038bec7b9b0e1ab703 eZPublish 4.5 - Passed Patch’s from https://jira.ez.no/browse/EZP-19544 are needed https://github.com/ezsystems/ezpublish-legacy-ee/commit/a9f44dfd63fc3ae13f8aedb36148ad264a759179 https://github.com/ezsystems/ezpublish-legacy-ee/commit/486f3bb https://github.com/ezsystems/ezpublish-legacy-ee/commit/59761005f343de19075f02799c83bce6ae329667
          Hide
          Joao Pingo (Inactive) added a comment -

          QA Approved

          Show
          Joao Pingo (Inactive) added a comment - QA Approved

            People

            • Assignee:
              Unassigned
              Reporter:
              Joao Inacio (Inactive)
            • Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 1 day
                1d