On Sep 26, 2011, at 11:43 , Ruudk wrote:

> I used the Symfony2 beta a couple of months ago and then there was a 
> shared=true/false option. That option has been removed. Why is this?
> 
> I want to create a new instance everytime I request a service from the 
> container.
> 
> $this->get('mailer.new_message');
> 
> Should I use a factory service instead?

shared true/false was replaced by scope, which can now be "container" 
(previously shared true), "prototype" (previously false) and "request" for 
anything that is dependend on the request service or anything else that needs 
to be reinstantiated for every subrequest.

Lukas Kahwe Smith
[email protected]



-- 
If you want to report a vulnerability issue on symfony, please send it to 
security at symfony-project.com

You received this message because you are subscribed to the Google
Groups "symfony developers" 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-devs?hl=en

Reply via email to