• Share
  • Email
  • Embed
  • Like
  • Save
  • Private Content
Accelarating PHP Applications at INTAN Sabah Technology Updates 2011
 

Accelarating PHP Applications at INTAN Sabah Technology Updates 2011

on

  • 1,359 views

"Accelarating PHP Applications" Presented at INTAN Sabah Technology Updates 2011

"Accelarating PHP Applications" Presented at INTAN Sabah Technology Updates 2011

Statistics

Views

Total Views
1,359
Views on SlideShare
1,328
Embed Views
31

Actions

Likes
2
Downloads
12
Comments
0

1 Embed 31

http://phpcoe.mimos.my 31

Accessibility

Categories

Upload Details

Uploaded via as Adobe PDF

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

    Accelarating PHP Applications at INTAN Sabah Technology Updates 2011 Accelarating PHP Applications at INTAN Sabah Technology Updates 2011 Presentation Transcript

    • Accelerating PHP Applications Errazudin Ishakwww.mimos.my © 2009 MIMOS Berhad. All Rights Reserved.
    • Agenda Who Am I PHP Center of Excellence The Curious Case of Enterprise PHP Summarywww.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Me Senior engineer @ Mimos Berhad Focuses on web application development, deployment, performance and stability. 2009 : foss.my , MyGOSSCON 2010 : Entp. PHP Techtalk, BarcampKL, PHP Meetup, MOSC2010, PHPNW UK, PHP20102010, MyGOSSCONwww.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Agenda Who Am I PHP Centre of Excellence The Curious Case of Enterprise PHP Summarywww.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • phpcoe.mimos.mywww.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • phpcoe.mimos.my Top goals; • increasing the maturity of the PHP application life cycle, • showcasing the best practice of enterprise PHP development • contributing to/supporting PHP open source projects • supporting PHP user groups/communities • organizing conferences/seminar • developing localized training material • forming and maintaining partnerships with the communities and developing professional services.www.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Events : Enterprise PHP Tech talk www.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Events : Facebook Developer Garage www.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Events : PHP Malaysia Meetup www.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Events : PHP Northwest, UK www.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • http://goo.gl/EbTI Accelerating PHP Applicationwww.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • The Newswww.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • iSDP Intelligent Service Delivery Platformwww.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • The struggle begins..www.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Agenda Who Am I PHP Center of Excellence The Curious Case of Enterprise PHP (How actually we makes PHP apps fly) Summarywww.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Enterprise == ?www.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • DBA Enterprise PHP DesignerTEAM Sys. Ad Tester PHP Geek PM Project Lead BA www.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Enterprise PHPTEAMRequirement •Customer need this … •User want that … •My boss add this … •My BA... more headache … www.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • "Faster sites create happy users”– Google, April 9, 2010 www.mimos.my © 2011 MIMOS Berhad. All Rights Reserved. http://www.flickr.com/photos/36230948@N05/
    • Web Application Lifecycle • Planning o Requirement Analysis o Design • Execution o Code o Test • Deployment o Sys Adm nightmare?www.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Web Application Lifecycle • Planning o Requirement Analysis o Design • Execution o Code o Test • Deployment o Sys Adm nightmare?www.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Web Application Lifecycle • Planning o Requirement Analysis o Design • Execution o Code o Test • Deployment o Sys Adm nightmare?www.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Enterprise PHPTEAMRequirementArchitecture •Design Diagrams (Technical ) •HLD •Blueprint www.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • "Real performance is architecture-driven” - R.Lerdorfwww.mimos.my © 2011 MIMOS Berhad. All Rights Reserved. http://goo.gl/abCVp
    • "PHP is rarely the bottleneck” -R.Lerdorf www.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Front End Back Endwww.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Front End nginx Zend Serverwww.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Zend Server Back End MySQLwww.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Enterprise PHPTEAMRequirementArchitectureTools •Planning •Development •Deployment www.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Enterprise PHPTEAMRequirementArchitectureToolsFoundation •Stable? •Framework vs No-Framework •On Your Own Frame to-do work www.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Enterprise PHPTEAMRequirementArchitectureToolsFoundationDesign patterns •Best practice of solving probs. •MVC? www.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Enterprise PHPTEAMRequirementArchitectureToolsFoundationDesign patternsTesting •Developer, Unit, Functional, Performance, Integration, Usability www.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Enterprise PHPTEAMRequirementArchitectureToolsFoundationDesign patternsTestingOptimization •They want it fast •We need •Accelerator (eAccelerator, Alternative PHP Cache, ionCube PHP Accelerator,Turck MMCache,XCache,Nusphere PhpExpress,Zend Optimizer+,Zend Platform •Cache (Smarty, Zend_Cache, Memcached) www.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • "Premature optimization is the root of all evil ” - Donald Knuthwww.mimos.my © 2011 MIMOS Berhad. All Rights Reserved. http://goo.gl/twTea
    • Where to start • System calls o web server processes o Index o Web server config o Include o S-L-D-Ktrace / trusswww.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Find the culprit • Include hierachy > redundancy o Tools > pecl/inclued o include_once/require_once o Graphwww.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • "Profile your code to pinpoint bottlenecks” - Eric Higginswww.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Areas • Code • Network • DB • Systemwww.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Profiling Tools • xdebug • valgrind.org • Xhprof • Zend Studio/Serverwww.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Enterprise PHPTEAMRequirementArchitectureToolsFoundationDesign patternsTestingOptimizationSecurity •Prevention of harmful event(s) •Real Risk •Severe consequences www.mimos.my © 2011 MIMOS Berhad. All Rights Reserved. http://goo.gl/nPgwj
    • Enterprise PHPTEAMRequirementArchitectureToolsFoundationDesign patternsTestingOptimizationSecurityDeployment •Develop, Test, Deploy (Test, Live) •Simple XAMPP to HA, Scalable architecture www.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • “Every nanoseconds count!” - My Big Boss (your boss also) http://geekonfilm.files.wordpress.com/2009/09/vader.jpgwww.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Layers • Design o Algorithm used o Architecture o Special tricks • Code o Avoid ‘slowdowns’ • Deploy o “it works on my dev machine!”www.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Performance Enhancement • Measure • Benchmark • Analyse • (Loop?)www.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Key Points • Avoid Premature Optimization • Measuring Performance o Memory and CPU Measurement o Requests Per Second • Pinpointing The Cause Of Poor Performance • Code Profiling • Database Operations Analysis • General PHP Optimisation o Opcode Caching o Realpath Cachewww.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Key Points • General Zend Framework Optimization o Class Loading Optimisation o Configuring Default Caches o Cache At The Right Level o Minimising Include Paths • HTTP Server Optimization o Optimising Apaches Configuration o Avoiding Apache Completelywww.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Enterprise PHPTEAMRequirementArchitectureToolsFoundationDesign patternsTestingOptimizationSecurityDeploymentOperation •Helpdesk •Monitoring •Root cause analysis •Change management www.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Enterprise PHPTEAMRequirementArchitectureToolsFoundationDesign patternsTestingOptimizationSecurityDeploymentOperationwww.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Agenda Who Am I PHP Center of Excellence The Curious Case of Enterprise PHP Summarywww.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Checklist • Objectives & constraints • What is the Problems • Don’t make assumptions (VNV it) • Right tools (but tools is just a tools) • Use profiler with benchmarks • Resources are limited (monitor them)www.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • Ready to make your web apps fly?www.mimos.my © 2011 MIMOS Berhad. All Rights Reserved. http://goo.gl/abCVp
    • Resources• Eric Higgins, Google Webmaster code.google.com/speed/articles/optimizing-php.html• Rasmus’s talk at Hacker Dojo http://talks.php.net/show/digg/• code.google.com/speed/page-speed• developer.yahoo.com/performance/rules.html• www.zend.com/en/products/server• www.nginx.net• www.survivethedeepend.com• pecl.php.net/package/xhprof• github.com/facebook/xhprof www.mimos.my © 2011 MIMOS Berhad. All Rights Reserved.
    • THANK YOU @errazudin errazudin.ishak@mimos.my* All images, logos and data are the copyright oftheir respective owners www.mimos.my © 2009 MIMOS Berhad. All Rights Reserved.