Is there an event that gets fired after my custom services are created but before the controller action is called?
And is there a full list of all events in Symfony2?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
One of the nice things about the DIC (Dependency Injection Container) is that the services are only created when you actually need them. This means that most services will be invoked and thus created from within the controller.
To answer your question, there is the
kernel.requestevent that is fired before the controller, so you can use that.