Release Workflow: Code + Test Branch Code Test Integrate Release Stabilize • Scrum (or at least Agile) • As TDD as possible • Labs • A/B Testing • PoCs • Dark launch
Release Workflow: Integrate Branch Code Test Integrate Release Stabilize • Repo always available • Specific release date given by devops – Merge & wait for target • Only merge if 100% tests ok or specific approval • QA Regression & manual tests • Fix possible integration problems ASAP
Release Workflow: Release Branch Code Test Integrate Release Stabilize • 3 releases per week – DevOps goal: All weekdays • Latest stable changeset from Integration taken previous working day morning • Release doc, pre-release meetings • Staging servers to test with live data
Release Workflow: Stabilize Branch Code Test Integrate Release Stabilize • First code push: 8 AM – DevOps Goal: single push + release closed • Release window: 1-2 h – DevOps goal: < 30 minutes • Error stabilization or release rollback • Representatives from all involved teams
DVCS: Mercurial • http://mercurial.selenic.com/ • Syntax similar to SVN (our old system) • Easy API to plug our plugins and hooks • Cross-platform • Tuenti Addons: – Commit hooks to check syntax, push ticket #... • Problems: – Push/pulls through VPN are slow – Handling multiple repos still slow – Only one level of rollback!
Testing: PHPUnit • http://www.phpunit.de • Some caveats – Mocking just ‘works’ – PHP process spawning PHP tests • Tuenti Addons: – Vastly improved mocking framework – Shell scripts that isolate test batteries – Better integration with Selenium • Problems: – Our current FEFW does not cope perfectly with PHPUnit/Selenium
Testing: Selenium • http://seleniumhq.org/ • Running browser tests in FFox and IE • Tuenti Addons: –Custom build with some fixes • Problems: –Javascript handling/detection not perfect –AJAX far from optimal –IE runner is an iframe • Planned migration to Webdriver
Storage: MySQL • http://www.mysql.com/ | http://www.percona.com • Live site storage • Dev. env. storage – 1 DB per user (to run tests) – 1 shared DB (common faked data) • Clusters of master/slave DBs • Problems: – Slow when running tests – Shared dev DB has old-time inconsistencies
Configuration: Puppet • http://puppetlabs.com/ • Production machines • Jenkins nodes • VM management / Dev web servers config • Problems: – Wipes user config if not puppetized
Search: Sphinx • http://sphinxsearch.com/ • Non-realtime (index based) • Very fast • Problems – Index re-generation on dev & test env. – Could be more friendly to add new data
Statics bundling: YUI (II) • Tuenti Addons: – Caching builds – Line breaks each # characters (easier IE debugging) – CDNs handling • Problems: – Change in JS requires rebuilding even in dev. – Requires small migrations/changes in existing JS