SlideShare une entreprise Scribd logo
1  sur  37
Télécharger pour lire hors ligne
… to be precise: “PHP in real world”
 Introduction
 A look at PHP
 What is Enterprise
 Development Lifecycle
 Enterprise Techniques
 Take-Aways
 Open Discussion
Who is here?
 How many of us here are:

  • Management / Decision makers

  • Project Managers

  • Developers – PHP

  • Developers – Other (.NET/RoR/Python/Java/…)

  • Student / Hobbyist
Past and Present
 Made for the web
 Low learning curve
 Short time-to-market
 Huge active community
 Platform independent (Linux, windows, …)
 Open source
 Versatile
 Backed by Zend, Microsoft, IBM, etc.
 “PHP is for hobbyists”
  • Low learning curve
  • Proper software engineering => proper quality

 “PHP is insecure”
  • PHP is a language; it’s the programmer that implements
    security

 “PHP is not a real language”
  • It’s a dynamic scripting language; but a powerful one
 “PHP does not scale”
  • Most often PHP is not the bottleneck, DB is
  • Language does not scale, architecture does

 “PHP is not ready for Enterprise”
  • Already running in mission-critical enterprises
  • More on this later
When to consider something enterprise, and why
 Customizability
   • Adherence to business-specific rules

   • Adaption of changing business environment

   • Change of direction

 Scalability
   • Need to scale as business grows
   • Change in infrastructure
 Security
   • Security is priority #1

 Integration
   • Needs to work seamlessly with existing solutions

   • Should be open for collaboration

 Performance
   • Response time

   • Load time
How we do it in real life
 Analysis

 Design
 Coding

 Testing

 Deployment and Maintenance
 Scrum

 Extreme Programming (XP)

 Kanban

 OpenAgile
 Working software is delivered frequently

 Working software is the principal measure of progress

 Even late changes in requirements are welcomed

 Regular adaptation to changing circumstances

 Customer is a part of the team
How to get ready for the enterprise
 Simple code     Caching

 DRY             Debugging

 Code quality    Deployment

 Security        Performance

 Testing         Refactoring
 This is easier said than done

 Do the simplest thing that could possibly work.
 Do not run for complexity, complexity kills!
 Stick to standards

 Open source = open knowledge
 Reuse Experience

 Use Components

 Use Frameworks
 Static Code Analysis
   • Lint (php -l)
   • PHP_CodeSniffer

 Software Metrics
   • PHPUnit
   • PHP_Depend

 Output validation
   • Tidy
   • HTML/CSS validation
 Security is not an afterthought, it should be built within
  the system
 Trust no one
 Handle common issues:
   • XSS,
   • SQL/Code injection,
   • Session fixation,
   • Session hijacking,
   • CSRF
 Unit Tests

 Integration Tests
 Acceptance Tests

 Testing Tools:
   • PHPUnit (http://www.phpunit.de)

   • Selenium (http://seleniumhq.org)
 Use a compiler cache (Zend, APC, etc)

 Cache generated content:
  • Whole pages or fragments (disk, squid, memcache)

  • Database query results (query cache, memcache)

  • External data (memcache, disk)
 Create a test to expose each bug

 Keep the test, and run it often
 Tool:
   • xdebug (http://www.xdebug.org)

   • Tracing

   • Remote Debugging
 Always automate deployment
 Use 3 Systems
   • Development
   • Integration/Staging
   • Live
 Consider virtual machines / cloud hosting
 Do not guess where to start

 Profile your code
   • how often are functions called

   • how long does execution take

 Look for all possible execution path

 Tool:
   • xdebug (http://www.xdebug.org)
 Improve the design of software without changing its
  behavior

 Not adding new features

 “Cleaning up” code
 Keep refactoring your code constantly

 Use unit tests to ensure you don't break anything
 The Negatives
   • PHP does not always have all of the functionality needed

   • Java development/implementation is more difficult than many
     situations require

 The Positives
   • PHP will do most of what you need to do, easier.

   • Java can fill almost any feature void in PHP for a web-based
     deployment
Source: Kevin Schroeder (Zend)
 PHP is a serious language
 PHP is used in big, real world projects
 Good life cycle for project matters
 PHP can be used in conjunction with other technologies
 When developing software for enterprise:
   • Keep things simple
   • Accept change
   • Test early and often
   • Automate tests and deployment
Questions ??

Contenu connexe

Tendances

Testing Your Code as Part of an Industrial Grade Workflow
Testing Your Code as Part of an Industrial Grade WorkflowTesting Your Code as Part of an Industrial Grade Workflow
Testing Your Code as Part of an Industrial Grade Workflow
Pantheon
 

Tendances (20)

Php Dependency Management with Composer ZendCon 2017
Php Dependency Management with Composer ZendCon 2017Php Dependency Management with Composer ZendCon 2017
Php Dependency Management with Composer ZendCon 2017
 
Practical PHP Deployment with Jenkins
Practical PHP Deployment with JenkinsPractical PHP Deployment with Jenkins
Practical PHP Deployment with Jenkins
 
Foundations of Zend Framework
Foundations of Zend FrameworkFoundations of Zend Framework
Foundations of Zend Framework
 
Web development with Python
Web development with PythonWeb development with Python
Web development with Python
 
Creating a Smooth Development Workflow for High-Quality Modular Open-Source P...
Creating a Smooth Development Workflow for High-Quality Modular Open-Source P...Creating a Smooth Development Workflow for High-Quality Modular Open-Source P...
Creating a Smooth Development Workflow for High-Quality Modular Open-Source P...
 
Best Practices in PHP Application Deployment
Best Practices in PHP Application DeploymentBest Practices in PHP Application Deployment
Best Practices in PHP Application Deployment
 
Phalcon overview
Phalcon overviewPhalcon overview
Phalcon overview
 
Why Your Site is Slow: Performance Answers for Your Clients
Why Your Site is Slow: Performance Answers for Your ClientsWhy Your Site is Slow: Performance Answers for Your Clients
Why Your Site is Slow: Performance Answers for Your Clients
 
Releasing High Quality Packages - Longhorn PHP 2021
Releasing High Quality Packages - Longhorn PHP 2021Releasing High Quality Packages - Longhorn PHP 2021
Releasing High Quality Packages - Longhorn PHP 2021
 
WordPress automation and CI
WordPress automation and CIWordPress automation and CI
WordPress automation and CI
 
Behaviour testing for single-page applications and API’s
Behaviour testing for single-page applications and API’sBehaviour testing for single-page applications and API’s
Behaviour testing for single-page applications and API’s
 
Containerizing legacy applications
Containerizing legacy applicationsContainerizing legacy applications
Containerizing legacy applications
 
XDebug For php debugging
XDebug For php debuggingXDebug For php debugging
XDebug For php debugging
 
mod_php vs FastCGI vs FPM vs CLI
mod_php vs FastCGI vs FPM vs CLImod_php vs FastCGI vs FPM vs CLI
mod_php vs FastCGI vs FPM vs CLI
 
Virtualizing Development
Virtualizing DevelopmentVirtualizing Development
Virtualizing Development
 
Introduction to GoLang
Introduction to GoLangIntroduction to GoLang
Introduction to GoLang
 
Buildr - build like you code
Buildr -  build like you codeBuildr -  build like you code
Buildr - build like you code
 
Testing Your Code as Part of an Industrial Grade Workflow
Testing Your Code as Part of an Industrial Grade WorkflowTesting Your Code as Part of an Industrial Grade Workflow
Testing Your Code as Part of an Industrial Grade Workflow
 
PowerShell 101 - What is it and Why should YOU Care!
PowerShell 101 - What is it and Why should YOU Care!PowerShell 101 - What is it and Why should YOU Care!
PowerShell 101 - What is it and Why should YOU Care!
 
Magento 2 performance profiling and best practices
Magento 2 performance profiling and best practicesMagento 2 performance profiling and best practices
Magento 2 performance profiling and best practices
 

Similaire à Enterprise PHP

Continuous Integration In A PHP World
Continuous Integration In A PHP WorldContinuous Integration In A PHP World
Continuous Integration In A PHP World
Idaf_1er
 
Testing and DevOps Culture: Lessons Learned
Testing and DevOps Culture: Lessons LearnedTesting and DevOps Culture: Lessons Learned
Testing and DevOps Culture: Lessons Learned
LB Denker
 
ProdSec: A Technical Approach
ProdSec: A Technical ApproachProdSec: A Technical Approach
ProdSec: A Technical Approach
Jeremy Brown
 
Introduction to-automated-testing
Introduction to-automated-testingIntroduction to-automated-testing
Introduction to-automated-testing
BestBrains
 

Similaire à Enterprise PHP (20)

Dev ops ci-ap-is-oh-my_security-gone-agile_ut-austin
Dev ops ci-ap-is-oh-my_security-gone-agile_ut-austinDev ops ci-ap-is-oh-my_security-gone-agile_ut-austin
Dev ops ci-ap-is-oh-my_security-gone-agile_ut-austin
 
Nascenia: Road to Software Industry
Nascenia: Road to Software IndustryNascenia: Road to Software Industry
Nascenia: Road to Software Industry
 
Making security-agile matt-tesauro
Making security-agile matt-tesauroMaking security-agile matt-tesauro
Making security-agile matt-tesauro
 
Continuous Integration In A PHP World
Continuous Integration In A PHP WorldContinuous Integration In A PHP World
Continuous Integration In A PHP World
 
Case study
Case studyCase study
Case study
 
Tools for Software Testing
Tools for Software TestingTools for Software Testing
Tools for Software Testing
 
Introduction To Web Development & The New Digital Workplace
Introduction To Web Development & The New Digital WorkplaceIntroduction To Web Development & The New Digital Workplace
Introduction To Web Development & The New Digital Workplace
 
Programming languages and techniques for today’s embedded andIoT world
Programming languages and techniques for today’s embedded andIoT worldProgramming languages and techniques for today’s embedded andIoT world
Programming languages and techniques for today’s embedded andIoT world
 
Testing and DevOps Culture: Lessons Learned
Testing and DevOps Culture: Lessons LearnedTesting and DevOps Culture: Lessons Learned
Testing and DevOps Culture: Lessons Learned
 
Kku2011
Kku2011Kku2011
Kku2011
 
Lean-Agile Development with SharePoint - Bill Ayers
Lean-Agile Development with SharePoint - Bill AyersLean-Agile Development with SharePoint - Bill Ayers
Lean-Agile Development with SharePoint - Bill Ayers
 
Keeping up with PHP
Keeping up with PHPKeeping up with PHP
Keeping up with PHP
 
ProdSec: A Technical Approach
ProdSec: A Technical ApproachProdSec: A Technical Approach
ProdSec: A Technical Approach
 
Bootstrapping Quality
Bootstrapping QualityBootstrapping Quality
Bootstrapping Quality
 
Selenium for everyone
Selenium for everyoneSelenium for everyone
Selenium for everyone
 
5 Steps to Jump Start Your Test Automation
5 Steps to Jump Start Your Test Automation5 Steps to Jump Start Your Test Automation
5 Steps to Jump Start Your Test Automation
 
DevOps on AWS: Deep Dive on Continuous Delivery and the AWS Developer Tools
DevOps on AWS: Deep Dive on Continuous Delivery and the AWS Developer ToolsDevOps on AWS: Deep Dive on Continuous Delivery and the AWS Developer Tools
DevOps on AWS: Deep Dive on Continuous Delivery and the AWS Developer Tools
 
Introduction to Automated Testing
Introduction to Automated TestingIntroduction to Automated Testing
Introduction to Automated Testing
 
Introduction to-automated-testing
Introduction to-automated-testingIntroduction to-automated-testing
Introduction to-automated-testing
 
It's XP Stupid (2019)
It's XP Stupid (2019)It's XP Stupid (2019)
It's XP Stupid (2019)
 

Dernier

EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
Earley Information Science
 

Dernier (20)

Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 

Enterprise PHP

  • 1. … to be precise: “PHP in real world”
  • 2.  Introduction  A look at PHP  What is Enterprise  Development Lifecycle  Enterprise Techniques  Take-Aways  Open Discussion
  • 4.
  • 5.  How many of us here are: • Management / Decision makers • Project Managers • Developers – PHP • Developers – Other (.NET/RoR/Python/Java/…) • Student / Hobbyist
  • 7.
  • 8.
  • 9.
  • 10.  Made for the web  Low learning curve  Short time-to-market  Huge active community  Platform independent (Linux, windows, …)  Open source  Versatile  Backed by Zend, Microsoft, IBM, etc.
  • 11.
  • 12.  “PHP is for hobbyists” • Low learning curve • Proper software engineering => proper quality  “PHP is insecure” • PHP is a language; it’s the programmer that implements security  “PHP is not a real language” • It’s a dynamic scripting language; but a powerful one
  • 13.  “PHP does not scale” • Most often PHP is not the bottleneck, DB is • Language does not scale, architecture does  “PHP is not ready for Enterprise” • Already running in mission-critical enterprises • More on this later
  • 14. When to consider something enterprise, and why
  • 15.  Customizability • Adherence to business-specific rules • Adaption of changing business environment • Change of direction  Scalability • Need to scale as business grows • Change in infrastructure
  • 16.  Security • Security is priority #1  Integration • Needs to work seamlessly with existing solutions • Should be open for collaboration  Performance • Response time • Load time
  • 17. How we do it in real life
  • 18.  Analysis  Design  Coding  Testing  Deployment and Maintenance
  • 19.  Scrum  Extreme Programming (XP)  Kanban  OpenAgile
  • 20.  Working software is delivered frequently  Working software is the principal measure of progress  Even late changes in requirements are welcomed  Regular adaptation to changing circumstances  Customer is a part of the team
  • 21. How to get ready for the enterprise
  • 22.  Simple code  Caching  DRY  Debugging  Code quality  Deployment  Security  Performance  Testing  Refactoring
  • 23.  This is easier said than done  Do the simplest thing that could possibly work.  Do not run for complexity, complexity kills!
  • 24.  Stick to standards  Open source = open knowledge  Reuse Experience  Use Components  Use Frameworks
  • 25.  Static Code Analysis • Lint (php -l) • PHP_CodeSniffer  Software Metrics • PHPUnit • PHP_Depend  Output validation • Tidy • HTML/CSS validation
  • 26.  Security is not an afterthought, it should be built within the system  Trust no one  Handle common issues: • XSS, • SQL/Code injection, • Session fixation, • Session hijacking, • CSRF
  • 27.  Unit Tests  Integration Tests  Acceptance Tests  Testing Tools: • PHPUnit (http://www.phpunit.de) • Selenium (http://seleniumhq.org)
  • 28.  Use a compiler cache (Zend, APC, etc)  Cache generated content: • Whole pages or fragments (disk, squid, memcache) • Database query results (query cache, memcache) • External data (memcache, disk)
  • 29.  Create a test to expose each bug  Keep the test, and run it often  Tool: • xdebug (http://www.xdebug.org) • Tracing • Remote Debugging
  • 30.  Always automate deployment  Use 3 Systems • Development • Integration/Staging • Live  Consider virtual machines / cloud hosting
  • 31.  Do not guess where to start  Profile your code • how often are functions called • how long does execution take  Look for all possible execution path  Tool: • xdebug (http://www.xdebug.org)
  • 32.  Improve the design of software without changing its behavior  Not adding new features  “Cleaning up” code  Keep refactoring your code constantly  Use unit tests to ensure you don't break anything
  • 33.  The Negatives • PHP does not always have all of the functionality needed • Java development/implementation is more difficult than many situations require  The Positives • PHP will do most of what you need to do, easier. • Java can fill almost any feature void in PHP for a web-based deployment
  • 35.
  • 36.  PHP is a serious language  PHP is used in big, real world projects  Good life cycle for project matters  PHP can be used in conjunction with other technologies  When developing software for enterprise: • Keep things simple • Accept change • Test early and often • Automate tests and deployment