Upgrade to Pro — share decks privately, control downloads, hide ads and more …

SpreeConf 2014 - Ninefold Presents: Spree Performance

SpreeConf 2014 - Ninefold Presents: Spree Performance

Spree commerce is capable of sizzling performance and smooth scalability. But why does performance matter so much? Because time is money. Amazon found that every 100ms of average responsiveness improvement boosted their revenue by 1%. AOL, Google, Yahoo! and Shopzilla have found similar or greater effects. With this backdrop, Daniel Sim Lind leads us through the performance testing journey that Rails hosting platform provider Ninefold took with Spree. We'll deep dive into the methodology and tools, the analysis, using user happiness as a testing constant, the results - and what it all means for you. Includes hot-off-the-press Spree 2-2 with cacheing test results, and a cheeky Magento comparison.

Daniel Sim Lind

February 26, 2014
Tweet

Other Decks in Technology

Transcript

  1. 1. Set up a server. 2. Design a simulation. 3.

    Throw simulated users at the server. 4. Measure the latency.
  2. Here’s our tool chain: Chrome -> Developer tools provide data

    for the test plan. ! ruby-jmeter -> Provides ruby-based testing DSL. -> Generates JMeter XML. ! Flood.io -> Eats JMeter XML. -> Spin up a “Grid” of simulated users following the XML-defined script. -> Measures and reports response times.
  3. Flood.io Requires some understanding of JMeter. Scales as big as

    you want to pay for. Gives high-level and very granular results.
  4. Apdex. t = acceptable response time satisfied = response time

    < t tolerating = t < response time < 4t frustrated = response time > 4t Apdex [t] = (satisfied + (tolerating/2))/total requests
  5. Heroku details: • WEB_CONCURRENCY=7 
 (based on a series of

    tests and analysis of memory usage) ! • Use 2X sized dynos to ensure more memory and CPU resources ! • Postgres database : Crane configuration
  6. Test parameters: • Choose 5 configurations that range from $100

    per month to $1,000 per month.
 • Run flood.io tests using a 60 second ramp up and a 300 second test duration.
 • Vary the concurrent user count to discover the maximum number of users that can be serviced while maintaining an Apdex 0.95 [0.75]
  7. $0.00$ $100.00$ $200.00$ $300.00$ $400.00$ $500.00$ $600.00$ $700.00$ $800.00$ $900.00$

    $1,000.00$ $1,100.00$ $1,200.00$ 0$ 25$ 50$ 75$ 100$ 125$ 150$ 175$ 200$ 225$ 250$ 275$ 300$ 325$ 350$ 375$ 400$ 425$ 450$ 475$ 500$ 525$ 550$ 575$ 600$ 625$ Monthly(cost(for(test(configura2on( Maximum(concurrent(users(whilst(maintaining(Apdex(of(at(least(0.95(( How(much(does(it(cost(to(delight(my(customers?( Heroku$2X$ Ninefold$ Smooth scaling.
  8. $0.00$ $100.00$ $200.00$ $300.00$ $400.00$ $500.00$ $600.00$ $700.00$ $800.00$ $900.00$

    $1,000.00$ $1,100.00$ $1,200.00$ $1,300.00$ $1,400.00$ $1,500.00$ $1,600.00$ $1,700.00$ $1,800.00$ $1,900.00$ $2,000.00$ $2,100.00$ $2,200.00$ $2,300.00$ $2,400.00$ $2,500.00$ 0$ 25$ 50$ 75$ 100$ 125$ 150$ 175$ 200$ 225$ 250$ 275$ 300$ 325$ 350$ 375$ 400$ 425$ 450$ 475$ 500$ 525$ 550$ 575$ 600$ 625$ 650$ 675$ 700$ 725$ 750$ 775$ 800$ Monthly(cost(for(test(configura2on( Maximum(concurrent(users(whilst(maintaining(Apdex(of(at(least(0.95(( How(much(does(it(cost(to(delight(my(customers?( Ninefold$ Heroku$PX$ Smooth pricing.
  9. Visitors experiencing the best 10% of load times viewed 3

    times more pages than getting the worst 10%. http://assets.en.oreilly.com/1/event/29/The%20Secret%20Weapons%20of%20the%20AOL%20Optimization%20Team%20Presentation.pdf
  10. Load time: 6 seconds -> 1.2 seconds. Page views: up

    25%. Revenue: up 12%. http://www.slideshare.net/timmorrow/shopzilla-performance-by-design-2433735
  11. For every 100ms of load time improvement: Sales increased by

    1%. https://sites.google.com/site/glinden/Home/StanfordDataMining.2006-11-28.ppt?attredirects=0
  12. 1. Consistent performance. 2. Inexpensive. a) Bare VM pricing. b)

    Much lower sysadmin costs. Ninefold: 
 The platform without the penalty.
  13. 3. Smoothly scaling costs. 4. Easy scaling. 5. Just enough

    control. Ninefold: 
 The platform without the penalty.
  14. 1. Clone your store. 2. Design a simulation. 3. Run

    the simulation at scale. 4. Benchmark the results. 10 Spree store tests.