Issue Task Closed

#99851Cache/ApcuBackend: eliminate double serialization

TYPO3 GmbH TYPO3com 02/06/23, 16:43 updated 01/30/24, 09:06

Description

APCu can store arbitrary PHP data; it serializes all values when they are stored, and it has a pluggable serializer interface which can use serializers that are better than serialize(), such as “igbinary” (https://www.php.net/manual/en/book.igbinary.php and https://pecl.php.net/package/igbinary).

By not implementing TransientBackendInterface, the ApcuBackend forces class VariableFrontend to serialize all values into a string, but APCu serializes the string again. This is unnecessary overhead.

This adds TransientBackendInterface and removes the is_string() check. Double serialization is eliminated by this change.

This issue was automatically created from https://github.com/TYPO3/typo3/pull/417

Reviews 1

History 28

  1. Gerrit Code Review pushed patch set 1 for main to change 77717 status New Under Review 02/06/23, 16:44

  2. Gerrit Code Review pushed patch set 2 for main to change 77717 02/06/23, 17:11

  3. Gerrit Code Review pushed patch set 3 for main to change 77717 02/06/23, 18:58

  4. Gerrit Code Review pushed patch set 4 for main to change 77717 02/13/23, 15:22

  5. Gerrit Code Review pushed patch set 5 for main to change 77717 02/13/23, 15:28

  6. Gerrit Code Review pushed patch set 6 for main to change 77717 02/13/23, 15:47

  7. Anonymous commented and changed status Under Review Resolved done 0 % 100 % 02/13/23, 18:20

    Applied in changeset commit:f54531dad88addc4639f09b4cc37228524156d0c.

  8. Benni Mack changed status Resolved Closed 01/30/24, 09:06