Bug #80246

MemcachedBackend is a Transient backend

Added by Claus Due over 2 years ago. Updated about 1 year ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
-
Target version:
-
Start date:
2017-03-12
Due date:
% Done:

100%

TYPO3 Version:
8
PHP Version:
Tags:
Complexity:
Is Regression:
No
Sprint Focus:

Description

The Memcached cache backend in TYPO3 is a transient backend, meaning it is capable of storing values which are not strings. By implementing TransientBackendInterface it is communicated to VariableFrontend that the backend can receive and return object instances and other non-string values. This in turn improves performance and delegates the serialization to memcached's selected serializer (defined in php.ini settings). This also means that chunk-splitting will not happen when a non-string value is passed to the cache backend.

Drawbacks:

Since serialization is no longer done automatically, passing an object which when serialized and compressed exceeds the maximum bucket size for memcached. The result is that caching the entry fails, a log message gets recorded, and subsequent get/has returns FALSE for the ID.

It is extremely unlikely that any serialized and compressed objects exceed this limit.

Associated revisions

Revision 1181ff42 (diff)
Added by Claus Due over 2 years ago

[TASK] Make MemcachedBackend a transient backend

Allows passing non-string values to the backend, which
is perfectly allowed for this type of backend. The change
means that VariableFrontends used with this backend will
store non-string values without serializing, thus optimising
performance and transparency.

Key changes:

  • Exceptions are no longer thrown when a non-string is passed
  • Chunk-splitting does not happen on non-strings; entries
    exceeding the maximum bucket size get logged and ignored.
  • Serializer decision is delegated to memcached configuration.

Change-Id: Ie11736be621a2dd27bfde60b82cd5f6b3a04d981
Resolves: #80246
Releases: master
Reviewed-on: https://review.typo3.org/52015
Tested-by: TYPO3com <>
Reviewed-by: Claus Due <>
Tested-by: Claus Due <>
Reviewed-by: Elmar Hinz <>
Tested-by: Elmar Hinz <>
Reviewed-by: Christian Kuhn <>
Tested-by: Christian Kuhn <>

History

#1 Updated by Gerrit Code Review over 2 years ago

  • Status changed from New to Under Review

Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/52015

#2 Updated by Gerrit Code Review over 2 years ago

Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/52015

#3 Updated by Gerrit Code Review over 2 years ago

Patch set 3 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/52015

#4 Updated by Gerrit Code Review over 2 years ago

Patch set 4 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/52015

#5 Updated by Gerrit Code Review over 2 years ago

Patch set 5 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/52015

#6 Updated by Gerrit Code Review over 2 years ago

Patch set 6 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/52015

#7 Updated by Gerrit Code Review over 2 years ago

Patch set 7 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/52015

#8 Updated by Gerrit Code Review over 2 years ago

Patch set 8 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/52015

#9 Updated by Gerrit Code Review over 2 years ago

Patch set 9 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/52015

#10 Updated by Gerrit Code Review over 2 years ago

Patch set 10 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/52015

#11 Updated by Gerrit Code Review over 2 years ago

Patch set 11 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/52015

#12 Updated by Anonymous over 2 years ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100

#13 Updated by Benni Mack about 1 year ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF