Project

General

Profile

Actions

Task #104724

closed

Epic #104723: ext:adminpanel creates a huge mess

DI in admin panel broken due to ModuleDataStorageCollection

Added by Christian Kuhn 3 months ago. Updated about 1 month ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
AdminPanel
Target version:
-
Start date:
2024-08-24
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
13
PHP Version:
Tags:
Complexity:
Sprint Focus:

Description

ModuleDataStorageCollection extends SplObjectStorage.

This means it is a list of the module objects and those park 'moduleData' as 'info'.

This is then serialized and put into cache_adminpanel_requestcache, and later get() from cache again. (MainController).

Now, when any of such modules or submodules (like Event.php) have DI, those are serialized, and unserialized.

Well ... that's not good since it catapults the size of those cache entries far into MB range when DI is used. And worse, as soon as there is some closure in it (like Container has), serialize() will fail since closures can't be serialized. And hey: Never "cache" DI stuff ...

I for now push a WIP patch, that throws this object storage away and substitutes it with a array, with array-keys being the class names ... but i'm unsure if that's it.

See also #104725 of this epic as a second major fail.

This is not trivial to follow codewise, and it does not happen with all modules/submodules, depending on if they implement DataProviderInterface.


Related issues 4 (0 open4 closed)

Related to TYPO3 Core - Feature #86003: Add composition based API for the adminpanelClosedSusanne Moog2018-08-28

Actions
Related to TYPO3 Core - Feature #104773: Implement and use a core ViewFactoryInterfaceClosed2024-08-29

Actions
Related to TYPO3 Core - Feature #103504: Introduce a Fluid cObject for pagesClosedBenni Mack2024-03-29

Actions
Related to TYPO3 Core - Task #105291: Merge AdminPanelDataPersister into AdminPanelRendererClosed2024-10-13

Actions
Actions

Also available in: Atom PDF