Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Discourage the use of controllers as services #6611

Closed
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Fixed typo
javiereguiluz committed May 25, 2016
commit 83f68bfe1920e5c5b65bbd9fa26d3c7460006020
2 changes: 1 addition & 1 deletion cookbook/controller/service.rst
Original file line number Diff line number Diff line change
@@ -33,7 +33,7 @@ These are the main **drawbacks** of defining controllers as services:
* The constructor of the controllers can rapidly become too complex because you
must inject every single dependency needed by them.
* The code of the controllers is more verbose because you can't use the shortcuts
of the base controller and oyu must replace them with some lines of code.
of the base controller and you must replace them with some lines of code.

The recommendation from the :doc:`best practices </best_practices/controllers>`
is also valid for controllers defined as services: avoid putting your business