[TYPO3-mvc] Your experiences with the memory consumption of extbase + improment suggestions?

Franz Koch typo3.RemoveForMessage at elements-net.de
Thu Feb 4 20:59:29 CET 2010


Hi Masi,

> Get rid of cyclic object references before you unset/destroy an object using PHP 4.2 or 4.3 with
> disabled garbage collection.
>
> I found this tip recently on the Net and I could improve the memory situation by unsetting "parent
> pointers".

Thanks for the tip - I'll check that out.

> eg if you have a tree and each node holds a reference of its parent unsetting the root node will NOT
> free any menory. You have to walk the tree and unset the parent references before you do. Otherwise
> PHP will not destroy the node objects. Note: unsetting the references in the destructor is too late.
> You must call a custom destroy/shutdown() function that makes that cleanup for you. Really annoying.
>
> So you can either upgrade up 4.3 and see if it makes a difference or fiddle with ExtBase.

I wonder if real unsetting a object will ever work in extbase/FLOW3, as 
it's storing an instance of each object in a) the identity map and b) 
the persistence storage - regardless if it needs to be persisted or not 
:( So the only thing you could do is to fetch and create objects by your 
own?

-- 
kind regards,
Franz Koch


More information about the TYPO3-project-typo3v4mvc mailing list