Transcript
Page 1: A Perfect Website Launch Every Time

A Prefect Lunch, Evry Tim BADCramp 2013

Page 2: A Perfect Website Launch Every Time

A Perfect Launch, Every Time BADCamp 2013

Page 3: A Perfect Website Launch Every Time

Introductions

• Suzanne Aldrich

• Jon Peck

• Timani Tunduwani

Page 4: A Perfect Website Launch Every Time

Why Cake?

• CAXE

• Clarity

• Accuracy

• eXecution

• Empathy

Page 5: A Perfect Website Launch Every Time

Challenges for a perfect launch

• On time

• On budget

• On plan

Page 6: A Perfect Website Launch Every Time

Encourage self-sufficient users

• Reduce cost

• Make it easier to work and learn

• Maintain good communication

Page 7: A Perfect Website Launch Every Time

Onboarding: Converting Newbies to Pros

Suzanne

Page 8: A Perfect Website Launch Every Time

How we prepare for launch

• Aim: Get rid of all the “Oh my God!” moments

• Recipe: Set clients up for success

• Stakeholders:

• Project Manager - best practices

• Business owner - flawless launch

• Developer - knowledge of platform

• Sys Admin - delegation

Page 9: A Perfect Website Launch Every Time

Have a system and tools

• Specify workflow requirements

• Task list system - do.com, Trello, OmniPlan

• Orientation logistics - gCal

• Email templates & forms - wiki, Google

• Online calls & screenshares - GoToMeeting

• Slideshows & scripts - Keynote

Page 10: A Perfect Website Launch Every Time

Mapping the territory

• Scoping of responsibilities

• Managing expectations

• Channels of communication

• Emergency procedures

• Primary inbox

• Communicating blockers

Page 11: A Perfect Website Launch Every Time
Page 12: A Perfect Website Launch Every Time

Site Auditing: Landmines, acid pools, and dead weight.

Jon

Page 13: A Perfect Website Launch Every Time

Why audit sites?

• Ensure optimal configuration

• Every site is unique, but…

• Built with the same framework

• Similar architectural requirements

• One size fits most.

Page 14: A Perfect Website Launch Every Time

What is static program analysis?

• Performance & behavior gathering

• Does not execute

• Non-intrusive

• Automated

Page 15: A Perfect Website Launch Every Time

Why use static program analysis?

• Fast

• Repeatable

• Detects common problems

Page 16: A Perfect Website Launch Every Time

What is Site Audit?

• Drupal 7 static analysis

• https://drupal.org/project/site_audit

• Best practices

• Actionable report

• formats: drush, HTML, JSON

Page 17: A Perfect Website Launch Every Time

What can Site Audit analyze?

• Drupal caching settings

• Codebase and file size

• Database structure

• Modules, including duplicate / missing

• Non-standard code structures

• Views caching

• Watchdog logs

Page 18: A Perfect Website Launch Every Time

What does static analysis not address?

• DOM / front-end performance

• Usability and site experience

• Aesthetics

• Content

Page 19: A Perfect Website Launch Every Time

[demo]

Page 20: A Perfect Website Launch Every Time

Load Testing: Obliterate surprises with actionable results

Timani

Page 21: A Perfect Website Launch Every Time

What does a load test measure?

• Performance

• Smoke

• Spike

• Stress

• Capacity

Page 22: A Perfect Website Launch Every Time

Why load test?

• Resource planning

• A/B testing

• Budgeting

Page 23: A Perfect Website Launch Every Time

When should I test?

• Before you write your first line of code!

• Xdebug, Webgrind, Devel, Syslog, Watchdog, New Relic

• Incrementally during development

• Prior to launch

Page 24: A Perfect Website Launch Every Time

Caching

• Opcode Cache

• APC, Zend Opcache, eAccelerator

• Backends

• Memcached, Redis, MongoDB, file system, APC

• Front-end caching

• Varnish, Squid, reverse-proxy CDNs

Page 25: A Perfect Website Launch Every Time

Testing Varnish With Curl

curl  -­‐Ik  http://example.org  

X-­‐Varnish:  1844141790  1843977932  

cache-­‐control:  public,  max-­‐age=900  

expires:  Sun,  19  Nov  1978  05:00:00  GMT  

x-­‐drupal-­‐cache:  HIT  

x-­‐generator:  Drupal  7  (http://drupal.org)  

Via:  1.1  varnish  

Age:  697

Page 26: A Perfect Website Launch Every Time

What to expect during and after

• Benchmark often (datapoints vs aggregate)

• Be reasonable

• Numbers should dictate expectations (back-end not just Google analytics)

Page 27: A Perfect Website Launch Every Time
Page 28: A Perfect Website Launch Every Time

PHP Slow Log

[26-­‐Sep-­‐2012  23:41:50]    [pool  www]  pid  17761 script_filename  =  /.../index.php[0x0000000001006408]  execute()  /.../includes/database/database.inc:2139 [0x0000000001005cf0]  execute()  /.../includes/database/database.inc:664 [0x0000000001005a38]  query()  /.../includes/database/select.inc:1264 [0x0000000001004760]  execute()  /.../sites/all/modules/views/plugins/views_plugin_query_default.inc:1398[0x0000000001003c40]  execute()  /.../sites/all/modules/views/includes/view.inc:1098[0x00000000010027f8]  execute()  /.../sites/all/modules/views/includes/view.inc:1118

Page 29: A Perfect Website Launch Every Time

Nginx error log

013/10/21  17:14:07  [alert]  23647#0:  *53768  128  worker_connections  are  not  enough  while  connecting  to  upstream,  client:  127.0.0.1,  server:  ,  request:  “POST  /index.php?q=submit  HTTP/1.0”,  upstream:  “fastcgi://unix:/srv/bindings/.../run/php-­‐fpm.sock:”,  host:  “www.example.org”

Page 30: A Perfect Website Launch Every Time

MySQL slow log

#  Time:  130320    7:30:26  

#  User@Host:  db_user[db_database]  @  localhost  []  

#  Query_time:  4.545309    Lock_time:  0.000069  Rows_sent:  219    Rows_examined:  254  

SET  timestamp=1363779026;  

SELECT  option_name,  option_value  FROM  wp_options  WHERE  autoload  =  'yes';

Page 31: A Perfect Website Launch Every Time

The bite is worse than the bark!

• Pay attention to your watchdog

• 6662    11/Oct  21:41    warning    cron    Attempting  to  re-­‐run  cron  while  it  is  already  running.6652    11/Oct  15:05    warning    php      Warning:  Cannot  modify  header  information  -­‐  headers  already  sent  by  (output  started  at  /srv/www/code/includes/common.inc:2700)  in  drupal_goto()  (line6643    11/Oct  14:21    notice      php      Notice:  Trying  to  get  property  of  non-­‐object  in  cap_ui_preprocess_page()  (line  27  of  /srv/www/code/sites/all/themes/cap_ui/template.php).6595    11/Oct  13:00    notice      php      Notice:  Unknown:  Can  not  authenticate  to  IMAP  server:  [AUTHENTICATIONFAILED]  Invalid  credentials  (Failure)  (errflg=2)  in  main()  (line    of  ).6594    11/Oct  13:00    notice      php      Notice:  Unknown:  Retrying  PLAIN  authentication  after  [AUTHENTICATIONFAILED]  Invalid  credentials  (Failure)  (errflg=1)  in  main()  (line    of  ). 6593    11/Oct  13:00    notice      php      Notice:  Unknown:  Retrying  PLAIN  authentication  after  [AUTHENTICATIONFAILED]  Invalid  credentials  (Failure)  (errflg=1)  in  main()  (line    of  ).

Page 32: A Perfect Website Launch Every Time

New Relic

Page 33: A Perfect Website Launch Every Time

Who should execute the test

• Developers execute

• Involve stakeholders

Page 34: A Perfect Website Launch Every Time

Where to perform the test

• environment

• bandwidth

• resource limitations

• SAAS

Page 35: A Perfect Website Launch Every Time

Tools for load testing

• DIY and simple

• Apache Bench

• Complex / dynamic

• Apache JMeter

• Load Impact

• Load Storm

Page 36: A Perfect Website Launch Every Time

Interpreting results

• Hard numbers

• Business impact

Page 37: A Perfect Website Launch Every Time

Load Test report

Page 38: A Perfect Website Launch Every Time

What’s next?

• Own the results.

Page 39: A Perfect Website Launch Every Time

Thank you! !

Questions?


Top Related