Review main Abandoned

27222[TASK] Avoid redundant page cache entries

Bernhard Kraft CR 0 V 0 Hard +426 −2 updated 06/12/14, 12:23

Commit message

Cached pages cause huge amount of redundant data being stored via
the caching framework. Improved the situation by implementing a
caching frontend and backend especially for page cache.

This cache frontend/backend classes store redundant data only once.

Review

  • Code review CR 0
  • Verified V 0

Issues 1

Files 5

Review log 8

  1. Mr. Jenkins commented on patch set 1 CR -1 V -1 02/01/14, 02:20

  2. Christian Kuhn commented on patch set 1 CR -1 02/01/14, 10:10

    cf should not handle application specific concerns. If "content" and "cache_data" should be handled more clever, this separation should be done on page code level, not in the cf frontend / backends.
  3. Helmut Hummel commented on patch set 1 CR -1 02/01/14, 10:58

    Thanks Bernhard for digging into this. But I agree with Christian that this issue should be not be handled in the caching layer. @Bernhard: since you are currently into it: can you imagine a different approach? Maybe better cache identifiers?
  4. Bernhard Kraft commented on patch set 1 02/01/14, 11:18

    At least it wont be possible without any change to parts of the caching framework. For example the garbage collection task is much more complex. It can't simply delete expired cache entries but must also look for data entries which are not referenced anymore ... Currently the caching classes are somehow straight forward. In my oppinion handling redundant data is quite something which could get handled by the caching layer. i.e. also igbinary takes care of avoiding duplicate strings in a serialized binary stream. I guess it solves this by using kind of dictionaries. In the same way there could be intelligent backends :)
  5. Bernhard Kraft commented on patch set 1 02/01/14, 11:20

    In fact another approach for cleaning up unused entries would be to carry a usage count. Similar to php variables. But I fear this could lead to entries being stuck at "1 use" because of some php script abort ...
  6. Bernhard Kraft commented on patch set 1 02/07/14, 14:47

    Another reason for having "PageCacheFrontend" as cf frontent are hooks. If I would add the redundancy reducing code to the TyposcriptFrontendController (TSFE) every hook operating with cached pages would have to get modified and would have to be aware of the special circumstances. By having a caching frontend/backend which handles page caching a hook author would not have to take care of this.
  7. Bernhard Kraft commented on patch set 1 CR -1 06/12/14, 12:23

    I will abandon this patch in favour of creating an extension out of it if necessary.
  8. Bernhard Kraft abandoned the change 06/12/14, 12:23

    Should get implemented in an extension.