Uploaded image for project: 'eZ Publish / Platform'
  1. eZ Publish / Platform
  2. EZP-18806

ezcontentobject::assignednodes creates many copies of self, wasting memory

    XMLWordPrintable

Details

    • Icon: Improvement Improvement
    • Resolution: Unresolved
    • Icon: Medium Medium
    • None
    • 2011.9, 4.6.0-dev
    • Caching
    • None

    Description

      This is not optimal, as it means more memory usage.

      The patterns is:

      . ezcontentobject::assignednodes calls eZContentObjectTreeNode::makeObjectsArray( $nodesListArray )
      . makeObjectsArray has a $with_contentobject parameter, defaultinng to true

      so if an obj has 3 locations, when calling assignednodes eZ will create 3 nodes, and for each node create a new object which is in fact a copy of the existing one.

      Proposal: let assignednodes call makeObjectsArray() with a false 2nd parameter, and immediately afterwards inject $this into the created nodes by calling setObject() on them

      Attachments

        Activity

          People

            unknown unknown
            72f8acac-185f-4a54-9470-a7473f50daab@accounts.ibexa.co Gaetano Giunta
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated: