Hi guys, I just read through the chatlog and I feel that we're taking a wrong turn regarding the SwiftMailer initialization issue. I might have misunderstood the current direction, apologies if so, it's kind of hard to follow the discussion reading things back.
I personally think that the problem here is that SwiftMailer might not be used inside the controller we are injecting it in, not the fact that initialization is an expensive operation. Fabien opened an RFC for that a while back, how we should inject dependencies in the controller and looking at the issue with SwiftMailer it seems to me we have not yet found an optimal solution. Or at least, I feel creating proxies for each "expensive initialization service" dependency is a non-solution. Unfortunately the RFC document is no longer online but the discussions are: * http://groups.google.com/group/symfony-devs/browse_thread/thread/1e63b56a4189681/83ba5d2f179afb65?lnk=gst&q=rfc+dependencies#83ba5d2f179afb65 * http://groups.google.com/group/symfony-devs/browse_thread/thread/210d2ad7ad0ae45f/a5375115f44214d9?lnk=gst&q=rfc+dependencies#a5375115f44214d9 Now I understand the arguments that lead us to create a ContainerAwareInterface for controllers but wouldn't we be better of if we would just inject services into our controllers. At that point it is the developers responsibility to ensure that those services are used for those actions. If they might not be used, then there is probably happening to much in that controller anyway. Besides that there are the other widely known arguments regarding testing. One could even argue to use one class per action (which I still think is a relatively small cost but works great given you can still have a common base class to share methods and as a side-effect create really lean controller objects). So I guess my question is, do more people feel that we haven't yet found an optimal solution here? If so, I'll write up a proper proposal for one of the next IRC meetings. Kindest regards, Marijn On Dec 3, 3:57 pm, Lukas Kahwe Smith <[email protected]> wrote: > On 01.12.2010, at 21:34, Lukas Kahwe Smith wrote: > > > Hi, > > > Topics for tomorrow: > >http://www.doodle.com/s34rgud286f9iawr > > > BTW: I sort of scavenge the topics form the mailinglist, since there have > > been very few actual proposals for topics. I feel like this gives me a bit > > too much power in determining the topics especially since I am the most > > active new thread creator on this list. I am of course open to any > > suggestions for improvements in the process. > > here is the summary and > log:http://trac.symfony-project.org/wiki/IRCLogs20101202 > > regards, > 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
