myphp-busters:
symfony framework
    PHP Conference UK
       27-02-2009
Adam Savage
Jamie Hyneman
Stefan Koopmanschap
About me

•   Professional Services Consultant at Ibuildings

•   Husband, father of 2, slave of 6

•   Symfony advocate

...
The myths:
                      symfony is...
•   ... hard to learn

•   ... extremely coupled

•   ... not really progra...
What I want to prove...



•   symfony is not crap

•   symfony fits in of pookey’s 10%
Pookey’s 10%
Pookey’s 10%
<pookey> PHP is a fucking filthy horrible language in
                90% of usecases.
Pookey’s 10%
<pookey> PHP is a fucking filthy horrible language in
                90% of usecases.

<pookey> I will back t...
Pookey’s 10%
<pookey> PHP is a fucking filthy horrible language in
                90% of usecases.

<pookey> I will back t...
Pookey’s 10%
<pookey> PHP is a fucking filthy horrible language in
                90% of usecases.

<pookey> I will back t...
Pookey’s 10%
<pookey> PHP is a fucking filthy horrible language in
                90% of usecases.

<pookey> I will back t...
cc-by 2.0 http://www.flickr.com/photos/shonk/418180402/




Symfony is hard to learn
Steep Learning Curve


•   Full-stack

    •   MVC

    •   ORM

    •   YAML
Great documentation

•   The Definitive Guide to
    symfony

•   Practical Symfony

    •   Propel Edition

    •   Doctri...
Great documentation
•   Official books in digital
    form

•   Forms in Action

•   symfony and Doctrine

•   The Cookbook...
Community
•   IRC: #symfony on
    freenode

•   Forum

•   Mailinglists

•   Wiki

•   Snippets

•   Blog posts

•   Vari...
Symfony is hard to learn


•   Steep learning curve

•   Great documentation (online and offline)

•   Friendly and support...
Symfony is hard to learn



      The Verdict
Symfony is hard to learn



      The Verdict
Symfony is hard to learn



      The Verdict
cc-by 2.0 http://www.flickr.com/photos/u-suke/138067687/




Symfony is extremely coupled
Perhaps in 1.0


•   symfony was the glue between components

•   ORM integrated in the core

•   It was full-stack or not...
by-nc-nd 3.0 http://www.symfony-project.org/blog/2008/06/23/the-symfony-1-1-architecture




symfony platform
by-nc-nd 3.0 http://www.symfony-project.org/blog/2008/06/23/the-symfony-1-1-architecture




platform and framework
Symfony is extremely coupled




     by-nc-nd 3.0 http://www.symfony-project.org/blog/2009/02/18/dailymotion-powered-by-s...
Symfony is extremely coupled

•   1.0 had quite some coupling

•   1.1 introduced decoupling of the core: symfony
    plat...
Symfony is extremely coupled




        The Verdict
Symfony is extremely coupled




        The Verdict
Symfony is extremely coupled




        The Verdict
symfony is not really programming, just
            configuration
Just configuration is no fun
Programming should be fun


•   No boring repetitive tasks

•   No standard stuff you did 100 times before

•   Write cool...
Yes, there is configuration


•   To minimize the boring tasks

•   To ensure you don’t repeat yourself

•   To enable you ...
So what is configured?

•   database credentials

•   caching

•   access control (authorization and authentication)

•   a...
So where do I touch code?

•   Your custom complex business logic

•   Application specific controller code

•   View displ...
symfony is not really programming, just
            configuration




           The Verdict
symfony is not really programming, just
            configuration




           The Verdict
symfony is not really programming, just
            configuration




           The Verdict
by-nc-sa 2.0 http://www.flickr.com/photos/two-wrongs/205467442/




symfony is restrictive
symfony is restrictive


•   Default directory structure

•   Default set of classes

•   Default set of libraries

•   OR...
Default directory structure
•   Easily change the most
    important directory
    locations:

    •   document root

    ...
Default set of classes


•   Default set offers most
    common uses

•   Easy to use your own
    custom class using
    ...
Default set of libraries
•   Default libraries

    •   lime (unit testing)

    •   prototype

    •   scriptaculous

•  ...
ORM included


•   Propel is default

•   Doctrine is distributed with symfony

•   There is no need for an ORM
You can just disable both!
Hell, disable the database


•   When you don’t use the
    database

    •   Models approach web
        services
symfony is restrictive



     The Verdict
symfony is restrictive



     The Verdict
symfony is restrictive



     The Verdict
Symfony is badly performing
Symfony doesn’t perform
Symfony doesn’t perform
Disclaimer:
No benchmarks!
by-sa 2.0 http://www.flickr.com/photos/mattieb/131215442/
Symfony doesn’t perform



•   Slow

•   Hard on the server
Symfony doesn’t perform


•   Overhead

    •   just like any framework

    •   tweak it the right way
Symfony doesn’t perform

•   Select your caching strategy

    •   Page caching

    •   Function caching

    •   Query c...
Symfony doesn’t perform

•   Select your caching strategy

    •   Page caching

    •   Function caching

    •   Query c...
Cache
Cache
Symfony doesn’t perform

•   Turn off what you don’t need

    •   ORM

    •   Plugins

    •   Database

    •   Logging...
Symfony doesn’t perform


•   Don’t believe me!

    •   Yahoo! Answers

    •   Delicious.com

    •   DailyMotion.com
Symfony is badly performing




        The Verdict
Symfony is badly performing




        The Verdict
Symfony is badly performing




        The Verdict
by-nc-nd 2.0 http://www.flickr.com/photos/mandolux/34418046/




symfony is the ultimate tool
Symfony is the ultimate tool
• full-stack framework
• based on MVC
• automation of common tasks
• supports agile approach
...
Symfony is the ultimate tool
• full-stack framework
• based on MVC
• automation of common tasks
• supports agile approach
...
Symfony is the ultimate tool


•   Learning curve is more steep

•   Has to fit your project

•   Has to fit your project te...
symfony is the ultimate tool



        The Verdict
symfony is the ultimate tool



        The Verdict
symfony is the ultimate tool



        The Verdict
Reference

•   http://www.symfony-project.org/doc/

•   http://www.symfony-project.org/blog/2008/06/23/
    the-symfony-1-...
Questions?

•   http://joind.in/215

•   http://www.leftontheweb.com/

•   http://www.twitter.com/skoop

•   http://www.ib...
Myphp-busters: symfony framework
Myphp-busters: symfony framework
Upcoming SlideShare
Loading in...5
×

Myphp-busters: symfony framework

5,524

Published on

The myphp-busters presentation I did at the PHP UK Conference 2009 on symfony framework

Published in: Technology
0 Comments
10 Likes
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total Views
5,524
On Slideshare
0
From Embeds
0
Number of Embeds
2
Actions
Shares
0
Downloads
0
Comments
0
Likes
10
Embeds 0
No embeds

No notes for slide

Transcript of "Myphp-busters: symfony framework"

  1. 1. myphp-busters: symfony framework PHP Conference UK 27-02-2009
  2. 2. Adam Savage
  3. 3. Jamie Hyneman
  4. 4. Stefan Koopmanschap
  5. 5. About me • Professional Services Consultant at Ibuildings • Husband, father of 2, slave of 6 • Symfony advocate • Initiator of SymfonyCamp • Founder of symfony-framework.nl • Plugin author/maintainer
  6. 6. The myths: symfony is... • ... hard to learn • ... extremely coupled • ... not really programming, just configuration • ... restrictive • ... badly performing • ... the ultimate tool
  7. 7. What I want to prove... • symfony is not crap • symfony fits in of pookey’s 10%
  8. 8. Pookey’s 10%
  9. 9. Pookey’s 10% <pookey> PHP is a fucking filthy horrible language in 90% of usecases.
  10. 10. Pookey’s 10% <pookey> PHP is a fucking filthy horrible language in 90% of usecases. <pookey> I will back that up with NOTHING
  11. 11. Pookey’s 10% <pookey> PHP is a fucking filthy horrible language in 90% of usecases. <pookey> I will back that up with NOTHING <pookey> but it's FACT
  12. 12. Pookey’s 10% <pookey> PHP is a fucking filthy horrible language in 90% of usecases. <pookey> I will back that up with NOTHING <pookey> but it's FACT If you disagree: he’s here
  13. 13. Pookey’s 10% <pookey> PHP is a fucking filthy horrible language in 90% of usecases. <pookey> I will back that up with NOTHING <pookey> but it's FACT If you disagree: he’s here
  14. 14. cc-by 2.0 http://www.flickr.com/photos/shonk/418180402/ Symfony is hard to learn
  15. 15. Steep Learning Curve • Full-stack • MVC • ORM • YAML
  16. 16. Great documentation • The Definitive Guide to symfony • Practical Symfony • Propel Edition • Doctrine Edition • Various other languages
  17. 17. Great documentation • Official books in digital form • Forms in Action • symfony and Doctrine • The Cookbook • API documentation • Tutorials & Screencasts
  18. 18. Community • IRC: #symfony on freenode • Forum • Mailinglists • Wiki • Snippets • Blog posts • Various local sites
  19. 19. Symfony is hard to learn • Steep learning curve • Great documentation (online and offline) • Friendly and supportive community
  20. 20. Symfony is hard to learn The Verdict
  21. 21. Symfony is hard to learn The Verdict
  22. 22. Symfony is hard to learn The Verdict
  23. 23. cc-by 2.0 http://www.flickr.com/photos/u-suke/138067687/ Symfony is extremely coupled
  24. 24. Perhaps in 1.0 • symfony was the glue between components • ORM integrated in the core • It was full-stack or nothing
  25. 25. by-nc-nd 3.0 http://www.symfony-project.org/blog/2008/06/23/the-symfony-1-1-architecture symfony platform
  26. 26. by-nc-nd 3.0 http://www.symfony-project.org/blog/2008/06/23/the-symfony-1-1-architecture platform and framework
  27. 27. Symfony is extremely coupled by-nc-nd 3.0 http://www.symfony-project.org/blog/2009/02/18/dailymotion-powered-by-symfony
  28. 28. Symfony is extremely coupled • 1.0 had quite some coupling • 1.1 introduced decoupling of the core: symfony platform • it is now possible to use core symfony classes without symfony
  29. 29. Symfony is extremely coupled The Verdict
  30. 30. Symfony is extremely coupled The Verdict
  31. 31. Symfony is extremely coupled The Verdict
  32. 32. symfony is not really programming, just configuration
  33. 33. Just configuration is no fun
  34. 34. Programming should be fun • No boring repetitive tasks • No standard stuff you did 100 times before • Write cool stuff • Focus on the cool parts
  35. 35. Yes, there is configuration • To minimize the boring tasks • To ensure you don’t repeat yourself • To enable you to concentrate on complex logic
  36. 36. So what is configured? • database credentials • caching • access control (authorization and authentication) • application specific values • routing • admin generator
  37. 37. So where do I touch code? • Your custom complex business logic • Application specific controller code • View displays • Custom administration tasks • Your own libraries
  38. 38. symfony is not really programming, just configuration The Verdict
  39. 39. symfony is not really programming, just configuration The Verdict
  40. 40. symfony is not really programming, just configuration The Verdict
  41. 41. by-nc-sa 2.0 http://www.flickr.com/photos/two-wrongs/205467442/ symfony is restrictive
  42. 42. symfony is restrictive • Default directory structure • Default set of classes • Default set of libraries • ORM included
  43. 43. Default directory structure • Easily change the most important directory locations: • document root • cache directory • log directory • You usually don’t need to do this!
  44. 44. Default set of classes • Default set offers most common uses • Easy to use your own custom class using configuration
  45. 45. Default set of libraries • Default libraries • lime (unit testing) • prototype • scriptaculous • Dozens of plugins • jquery, dojo, extjs, YUI • PHPUnit
  46. 46. ORM included • Propel is default • Doctrine is distributed with symfony • There is no need for an ORM
  47. 47. You can just disable both!
  48. 48. Hell, disable the database • When you don’t use the database • Models approach web services
  49. 49. symfony is restrictive The Verdict
  50. 50. symfony is restrictive The Verdict
  51. 51. symfony is restrictive The Verdict
  52. 52. Symfony is badly performing
  53. 53. Symfony doesn’t perform
  54. 54. Symfony doesn’t perform
  55. 55. Disclaimer: No benchmarks!
  56. 56. by-sa 2.0 http://www.flickr.com/photos/mattieb/131215442/
  57. 57. Symfony doesn’t perform • Slow • Hard on the server
  58. 58. Symfony doesn’t perform • Overhead • just like any framework • tweak it the right way
  59. 59. Symfony doesn’t perform • Select your caching strategy • Page caching • Function caching • Query caching • Supercache!
  60. 60. Symfony doesn’t perform • Select your caching strategy • Page caching • Function caching • Query caching • Supercache!
  61. 61. Cache
  62. 62. Cache
  63. 63. Symfony doesn’t perform • Turn off what you don’t need • ORM • Plugins • Database • Logging • Helpers
  64. 64. Symfony doesn’t perform • Don’t believe me! • Yahoo! Answers • Delicious.com • DailyMotion.com
  65. 65. Symfony is badly performing The Verdict
  66. 66. Symfony is badly performing The Verdict
  67. 67. Symfony is badly performing The Verdict
  68. 68. by-nc-nd 2.0 http://www.flickr.com/photos/mandolux/34418046/ symfony is the ultimate tool
  69. 69. Symfony is the ultimate tool • full-stack framework • based on MVC • automation of common tasks • supports agile approach • MIT license • DRY
  70. 70. Symfony is the ultimate tool • full-stack framework • based on MVC • automation of common tasks • supports agile approach • MIT license • DRY • All the buzzwords
  71. 71. Symfony is the ultimate tool • Learning curve is more steep • Has to fit your project • Has to fit your project team • There is no single ultimate tool
  72. 72. symfony is the ultimate tool The Verdict
  73. 73. symfony is the ultimate tool The Verdict
  74. 74. symfony is the ultimate tool The Verdict
  75. 75. Reference • http://www.symfony-project.org/doc/ • http://www.symfony-project.org/blog/2008/06/23/ the-symfony-1-1-architecture • http://www.symfony-project.org/blog/2009/02/18/ dailymotion-powered-by-symfony • http://www.symfony-framework.nl/
  76. 76. Questions? • http://joind.in/215 • http://www.leftontheweb.com/ • http://www.twitter.com/skoop • http://www.ibuildings.com/ • http://www.slideshare.net/skoop

×