MidCamp 2014 - A Perfect Launch, Every Time
-
Upload
suzanne-aldrich -
Category
Internet
-
view
164 -
download
2
description
Transcript of MidCamp 2014 - A Perfect Launch, Every Time
A Perfect Launch,Every Time
MidCamp 2014
What is a perfect launch?● Schedule - On Time● Cost - On Budget● Scope - On Plan
A Perfect Launch Recipe● Launch Team - Onboarding● Launch Check - Best Practices● Load Test - Performance Tuning
Launch TeamOnboarding
How we prepare for launch● Goal: Get rid of all the “uh-oh” moments● Method: Set clients up for success● Stakeholders:
○ Project Manager - scheduling, best practices○ Developer - platform knowledge, integration○ Sys Admin - responsibilities, delegation○ Business owner - flawless launch
Have a system and tools● Specify common workflow requirements
○ Repeatable tasks, delegatable● Project management - Wrike, JIRA, etc.● Orientation logistics
○ Scheduling - calendar, deadlines○ Real-time communication
■ Phone, Video Conference, GoToMeeting, IRC○ Training - documentation, Slides, Videos
Mapping the terrain● Scoping of responsibilities
○ Reduce confusion, set stage● Channels of communication
○ Define emergency procedures○ Issue tracking as primary inbox
● Staying in touch○ Available, open, and regular○ Proactive
Launch CheckBest Practices
What is Site Audit?● Drupal 7 static analysis
○ https://drupal.org/project/site_audit● Best practices● Actionable report● Vendor agnostic
○ Optional Pantheon specific recommendations
What can an audit analyze?● Drupal caching settings● Codebase and file size● Database structure● Modules, including duplicate / missing● Non-standard code structures● Views caching● Watchdog logs
Drupal caching settings
Drupal cron
Drupal’s database
Extensions (modules & themes)
Views
Watchdog
● Simple Drupal 7 site● Apache Bench
○ 10,000 requests to home page (5 concurrent)● Warmed cache, cleared watchdog● Comparison
○ Bad config, 1 PHP notice and warning in theme○ Good config, no PHP notices or warnings
Test Configuration
Result? Doubled performance.Bad config, errors● 20 min, 52 sec● Requests per
second: 7.98● Time per request:
626.192 ms
Good config, no errors● 10 min, 25 sec● Requests per
second: 15.99● Time per request:
312.780 ms
Good configuration matters.
Load TestingPerformance Tuning
Why load test?● Validate response times under peak load● Smoke - operations under normal load● Stress - behavior past peak load
○ Spike - short bursts● Capacity - plan for growth
Who should execute load tests?● Developers execute● Involve stakeholders
Tools for load testing● DIY and simple
○ Apache Bench● Complex / dynamic
○ Apache JMeter○ Load Impact○ Load Storm
When should I load test?● Before you write your first line of code!
○ Xdebug, Webgrind, Devel, Syslog, Watchdog, New Relic
● Incrementally during development● Prior to launch
Where do I perform load tests?● Live environment
○ Bandwidth● Resource limitations● SaaS
What to expect during & after● Benchmark often (datapoints vs aggregate)● Be reasonable● Numbers should dictate expectations (back-
end not just Google analytics)
Caching● Opcode Cache
○ APC, Zend Opcache, eAccelerator● Backends
○ Memcached, Redis, MongoDB, file system, APC● Front-end caching
○ Varnish, Squid, reverse-proxy CDNs
Back-end caching
Redis: Engage!
Front-end caching
Anonymous page caching: Disabled!
Testing Varnish with cURL
PHP Slow Log
Nginx error log
MySQL slow log
Pay attention to watchdog
Good load test
Bad load test
Interpreting results● Hard numbers● Business impact
Own the results.
Thank you! Questions?