Thanks!  I was thinking of this kind of solution also, but I wasn't
sure how long it would take me to figure out.  I'm mostly a Java/J2EE
guy, so PHP is a bit new to me.

I am curious to hear what the comments on this patch will be after
review.

Steve

On Jun 11, 4:49 am, Sergey Stepanov <[email protected]> wrote:
> Try this.
>
> http://trac.symfony-project.org/ticket/6226
>
> On 11.06.2009, at 9:54, pghoratiu wrote:
>
>
>
>
>
> > Hi!
>
> > I had some problems also with php memory collection, the main problem
> > was with circular reference used in propel when dealing objects.
>
> > 1. Circular reference - having two related objects A, B the following
> > will generate a memory leak becase A is referencing object B and B is
> > referencing object A at the same time:
> > A->add(B);
> > A->save();
>
> > but if you save each object one by one without trying to save them at
> > once it should work fine:
> > A->save()
> > B->setWhateverId(A->getId())
> > B->save()
>
> > When you have a php script running on the server web server it's not a
> > big problem because the process completes quickly and all alocated
> > memory is released, problems are usually with CLI and long running
> > processes.
>
> > 2. Another thing to watch out if you manipulate large number of
> > objects within a function, the objects are released only after the
> > function completes. This depends on the given situation, i did not
> > encounter problems with this myself.
>
> >    gabriel
>
> > On Jun 10, 9:25 pm, Nickolas Daskalou <[email protected]> wrote:
> >> Could be due to PHP's garbage collection not working properly on  
> >> some types
> >> of objects. I remember reading about it a while ago, not sure if  
> >> there is a
> >> fix for it yet.
>
> > >
> --------------
> SAD Group - web & software development subcontractor
> Sergey Stepanov
> E-mail: [email protected]
> Mobile: +375-297518326
>
>  smime.p7s
> 5KViewDownload

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"symfony users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/symfony-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to