SlideShare a Scribd company logo
1 of 18
Download to read offline
Is it Web Scale?
              	
  
     Mikael	
  Berggren	
  
    miken@spo1fy.com	
  
Who	
  is	
  this	
  old	
  guy?	
  
•  Web	
  Team	
  Lead	
  @	
  Spo1fy	
  
•  Started	
  back	
  in	
  the	
  the	
  glory	
  days	
  of	
  2000	
  
•  Only	
  works	
  for	
  companies	
  beginning	
  with	
  an	
  S	
  
   (Spray,	
  Stardoll	
  &	
  Spo1fy)	
  
Is	
  /dev/null	
  web	
  scale?	
  




    “Mongo	
  DB	
  is	
  Web	
  Scale”	
  –	
  YouTube.com	
  
Success	
  in	
  scale	
  fail	
  
•  Choose	
  by	
  buzz	
  /	
  trends	
  
•  Use	
  technology	
  suitable	
  for	
  something	
  
   completely	
  different	
  
•  Web	
  frameworks	
  
•  Don’t	
  measure	
  or	
  look	
  at	
  graphs	
  
“We’re	
  using	
  X	
  and	
  it	
  scales”	
  
•  There	
  is	
  no	
  magic	
  solu1on	
  that	
  scales	
  out	
  of	
  
   the	
  box	
  
•  Choose	
  the	
  technology	
  you’re	
  familiar	
  with	
  
•  Middle	
  bird	
  get’s	
  the	
  worm	
  
What	
  is	
  scaling?	
  
•    It’s	
  about	
  lying	
  :)	
  
•    Take	
  control	
  of	
  your	
  code	
  
•    Push	
  instead	
  of	
  pull	
  
•    Finding	
  boZlenecks	
  and	
  fix	
  them	
  
•    Avoid	
  SPoF	
  as	
  much	
  as	
  you	
  can	
  
•    Measure	
  and	
  analyze	
  
Cache	
  is	
  king!	
  
•      Cache	
  on	
  mul1ple	
  instances	
  
•      Cache	
  as	
  close	
  to	
  the	
  final	
  result	
  as	
  possible	
  
•      Memcache	
  is	
  good	
  
•      but	
  flat	
  files	
  is	
  even	
  beZer	
  

	
  
Using	
  memcache	
  
•  Local	
  &	
  Global	
  instances	
  
•  Global:	
  For	
  everything	
  that	
  needs	
  to	
  be	
  
   distributed	
  and	
  synchronized	
  
•  Local:	
  For	
  everything	
  else	
  
•  Make	
  sure	
  failovers	
  work	
  correctly	
  
•  Use	
  getMul1	
  when	
  possible	
  
•  Have	
  several	
  small	
  instances	
  instead	
  of	
  one	
  
   large	
  
File	
  cache	
  
•    Fast	
  and	
  reliable	
  
•    No	
  3rd	
  party	
  dependencies	
  
•    Used	
  ocen	
  =>	
  Really	
  fast	
  access	
  
•    Easy	
  to	
  scale	
  
•    Atomic	
  updates	
  
Web	
  frameworks?	
  No	
  thanks!	
  
•  Never	
  built	
  for	
  your	
  specific	
  needs.	
  If	
  they	
  are,	
  
   you’re	
  damn	
  lucky	
  :)	
  
•  Hard	
  to	
  control	
  data	
  and	
  request	
  handling	
  
   your	
  way	
  (plugins,	
  modules)	
  
•  A	
  lot	
  of	
  overhead	
  for	
  each	
  request	
  
Database	
  scaling	
  
•    Do	
  your	
  homework	
  on	
  indexes	
  and	
  queries	
  
•    Test	
  your	
  knowledge	
  on	
  indexes	
  and	
  queries	
  
•    Use	
  slave	
  nodes	
  for	
  reads	
  
•    Horizontal	
  sharding	
  for	
  segments	
  of	
  users	
  
•    Ver1cal	
  sharding	
  for	
  user-­‐data	
  
RDB	
  vs.	
  NoSQL	
  
•  “No”	
  in	
  NoSQL	
  stands	
  for	
  “Not	
  Only”	
  
•  Use	
  the	
  correct	
  storage	
  for	
  your	
  purpose	
  
•  Don’t	
  do	
  as	
  Digg.com…	
  
Scaling	
  at	
  Stardoll	
  
•    >3500	
  dynamic	
  PV/s	
  
•    Horizontal	
  sharding	
  of	
  user-­‐data	
  
•    Pre-­‐genera1on	
  of	
  content	
  
•    Measuring	
  render-­‐1me	
  for	
  each	
  page	
  
Scaling	
  at	
  Spo1fy	
  
•  We	
  said	
  “Bye	
  Wordpress!”	
  and	
  the	
  servers	
  
   where	
  happy	
  again	
  
•  95%	
  of	
  all	
  content:	
  flat	
  files	
  
•  Dependencies	
  on	
  shared	
  services	
  
•  Handle	
  huge	
  spikes	
  in	
  traffic	
  
PV/s	
  
Recommenda1ons	
  
•    Have	
  a	
  code	
  standard	
  everyone	
  must	
  follow!	
  
•    Great	
  error	
  handling	
  and	
  logging	
  
•    Possibility	
  to	
  disable	
  features/func1onality	
  
•    Try	
  to	
  do	
  requests	
  asynchronous	
  
•    Avoid	
  race	
  condi1ons	
  
•    Monitor,	
  measure	
  and	
  analyze	
  	
  !important	
  
Questions?
And btw,
we’re hiring
          	
  
  spo1fy.com/jobs	
  

More Related Content

What's hot

An Agile Approach to Machine Learning
An Agile Approach to Machine LearningAn Agile Approach to Machine Learning
An Agile Approach to Machine Learning
Randy Shoup
 

What's hot (20)

Cvcc performance tuning
Cvcc performance tuningCvcc performance tuning
Cvcc performance tuning
 
Cloud tools
Cloud toolsCloud tools
Cloud tools
 
Agile tour agile development
Agile tour   agile developmentAgile tour   agile development
Agile tour agile development
 
Freelancing and side-projects on Rails
Freelancing and side-projects on RailsFreelancing and side-projects on Rails
Freelancing and side-projects on Rails
 
Windycityrails page performance
Windycityrails page performanceWindycityrails page performance
Windycityrails page performance
 
WordPress Optimization - Pubcon Las Vegas 2014
WordPress Optimization - Pubcon Las Vegas 2014WordPress Optimization - Pubcon Las Vegas 2014
WordPress Optimization - Pubcon Las Vegas 2014
 
Best practices with development of enterprise-scale SharePoint solutions - Pa...
Best practices with development of enterprise-scale SharePoint solutions - Pa...Best practices with development of enterprise-scale SharePoint solutions - Pa...
Best practices with development of enterprise-scale SharePoint solutions - Pa...
 
Database Opt
Database Opt Database Opt
Database Opt
 
Why Enterprises Are Embracing the Cloud
Why Enterprises Are Embracing the CloudWhy Enterprises Are Embracing the Cloud
Why Enterprises Are Embracing the Cloud
 
Hiep le - xp should be dead! here is why.
Hiep le - xp should be dead! here is why. Hiep le - xp should be dead! here is why.
Hiep le - xp should be dead! here is why.
 
[Rakuten TechConf2014] [C-2] Big Data for eBooks and eReaders
[Rakuten TechConf2014] [C-2] Big Data for eBooks and eReaders[Rakuten TechConf2014] [C-2] Big Data for eBooks and eReaders
[Rakuten TechConf2014] [C-2] Big Data for eBooks and eReaders
 
DEVOPS TOOLS SWOT ANALYSIS
DEVOPS TOOLS SWOT ANALYSISDEVOPS TOOLS SWOT ANALYSIS
DEVOPS TOOLS SWOT ANALYSIS
 
Dev/Test in the Cloud - F
Dev/Test in the Cloud - FDev/Test in the Cloud - F
Dev/Test in the Cloud - F
 
An Agile Approach to Machine Learning
An Agile Approach to Machine LearningAn Agile Approach to Machine Learning
An Agile Approach to Machine Learning
 
(Best) Practices for the Solo Developer
(Best) Practices for the Solo Developer(Best) Practices for the Solo Developer
(Best) Practices for the Solo Developer
 
Windy cityrails performance_tuning
Windy cityrails performance_tuningWindy cityrails performance_tuning
Windy cityrails performance_tuning
 
XXLWEB
XXLWEBXXLWEB
XXLWEB
 
Minimum Viable Architecture - Good Enough is Good Enough
Minimum Viable Architecture - Good Enough is Good EnoughMinimum Viable Architecture - Good Enough is Good Enough
Minimum Viable Architecture - Good Enough is Good Enough
 
14 Habits of Great SQL Developers
14 Habits of Great SQL Developers14 Habits of Great SQL Developers
14 Habits of Great SQL Developers
 
Continuous database deployment
Continuous database deploymentContinuous database deployment
Continuous database deployment
 

Viewers also liked (9)

OPTIMERA STHLM! Måns Jonasson
OPTIMERA STHLM! Måns JonassonOPTIMERA STHLM! Måns Jonasson
OPTIMERA STHLM! Måns Jonasson
 
OPTIMERA STHLM! Henrik Nordström
OPTIMERA STHLM! Henrik NordströmOPTIMERA STHLM! Henrik Nordström
OPTIMERA STHLM! Henrik Nordström
 
OPTIMERA STHLM! Loadimpact
OPTIMERA STHLM! LoadimpactOPTIMERA STHLM! Loadimpact
OPTIMERA STHLM! Loadimpact
 
Anders Rafting
Anders RaftingAnders Rafting
Anders Rafting
 
Per Blixt
Per BlixtPer Blixt
Per Blixt
 
OPTIMERA STHLM! Fleecelabs
OPTIMERA STHLM! FleecelabsOPTIMERA STHLM! Fleecelabs
OPTIMERA STHLM! Fleecelabs
 
OPTIMERA STHLM! Martin Källström
OPTIMERA STHLM! Martin KällströmOPTIMERA STHLM! Martin Källström
OPTIMERA STHLM! Martin Källström
 
Optimera STHLM 2011 - Ragnar Lönn, Load Impact
Optimera STHLM 2011 - Ragnar Lönn, Load ImpactOptimera STHLM 2011 - Ragnar Lönn, Load Impact
Optimera STHLM 2011 - Ragnar Lönn, Load Impact
 
Optimera STHLM 2011 - Tobias Järlund, Aftonbladet
Optimera STHLM 2011 - Tobias Järlund, AftonbladetOptimera STHLM 2011 - Tobias Järlund, Aftonbladet
Optimera STHLM 2011 - Tobias Järlund, Aftonbladet
 

Similar to Optimera STHLM 2011 - Mikael Berggren, Spotify

My site is slow
My site is slowMy site is slow
My site is slow
hernanibf
 
Build software like a bag of marbles, not a castle of LEGO®
Build software like a bag of marbles, not a castle of LEGO®Build software like a bag of marbles, not a castle of LEGO®
Build software like a bag of marbles, not a castle of LEGO®
Hannes Lowette
 
Getting started with dev tools (atl)
Getting started with dev tools (atl)Getting started with dev tools (atl)
Getting started with dev tools (atl)
Thinkful
 
Driving application development through behavior driven development
Driving application development through behavior driven developmentDriving application development through behavior driven development
Driving application development through behavior driven development
Einar Ingebrigtsen
 
Unbreaking Your Django Application
Unbreaking Your Django ApplicationUnbreaking Your Django Application
Unbreaking Your Django Application
OSCON Byrum
 

Similar to Optimera STHLM 2011 - Mikael Berggren, Spotify (20)

Scaling a High Traffic Web Application: Our Journey from Java to PHP
Scaling a High Traffic Web Application: Our Journey from Java to PHPScaling a High Traffic Web Application: Our Journey from Java to PHP
Scaling a High Traffic Web Application: Our Journey from Java to PHP
 
Scaling High Traffic Web Applications
Scaling High Traffic Web ApplicationsScaling High Traffic Web Applications
Scaling High Traffic Web Applications
 
Django production
Django productionDjango production
Django production
 
My Site is slow - Drupal Camp London 2013
My Site is slow - Drupal Camp London 2013My Site is slow - Drupal Camp London 2013
My Site is slow - Drupal Camp London 2013
 
My site is slow
My site is slowMy site is slow
My site is slow
 
What Drove Wordnik Non-Relational?
What Drove Wordnik Non-Relational?What Drove Wordnik Non-Relational?
What Drove Wordnik Non-Relational?
 
Rapid Evolution of Web Dev? aka Talking About The Web
Rapid Evolution of Web Dev? aka Talking About The WebRapid Evolution of Web Dev? aka Talking About The Web
Rapid Evolution of Web Dev? aka Talking About The Web
 
Data Modeling for NoSQL
Data Modeling for NoSQLData Modeling for NoSQL
Data Modeling for NoSQL
 
Intro to SharePoint 2010 development for .NET developers
Intro to SharePoint 2010 development for .NET developersIntro to SharePoint 2010 development for .NET developers
Intro to SharePoint 2010 development for .NET developers
 
Lean Startup with WebObjects
Lean Startup with WebObjectsLean Startup with WebObjects
Lean Startup with WebObjects
 
Tales from the Platform Trade
Tales from the Platform TradeTales from the Platform Trade
Tales from the Platform Trade
 
Large Scale Modeling Overview
Large Scale Modeling OverviewLarge Scale Modeling Overview
Large Scale Modeling Overview
 
Inside Wordnik's Architecture
Inside Wordnik's ArchitectureInside Wordnik's Architecture
Inside Wordnik's Architecture
 
Build software like a bag of marbles, not a castle of LEGO®
Build software like a bag of marbles, not a castle of LEGO®Build software like a bag of marbles, not a castle of LEGO®
Build software like a bag of marbles, not a castle of LEGO®
 
Getting started with dev tools (atl)
Getting started with dev tools (atl)Getting started with dev tools (atl)
Getting started with dev tools (atl)
 
Maglev-A different way to develop with Ruby
Maglev-A different way to develop with RubyMaglev-A different way to develop with Ruby
Maglev-A different way to develop with Ruby
 
Jax Devops 2017 Succeeding in the Cloud – the guidebook of Fail
Jax Devops 2017  Succeeding in the Cloud – the guidebook of FailJax Devops 2017  Succeeding in the Cloud – the guidebook of Fail
Jax Devops 2017 Succeeding in the Cloud – the guidebook of Fail
 
Driving application development through behavior driven development
Driving application development through behavior driven developmentDriving application development through behavior driven development
Driving application development through behavior driven development
 
Running MongoDB in the Cloud
Running MongoDB in the CloudRunning MongoDB in the Cloud
Running MongoDB in the Cloud
 
Unbreaking Your Django Application
Unbreaking Your Django ApplicationUnbreaking Your Django Application
Unbreaking Your Django Application
 

More from .SE (Stiftelsen för Internetinfrastruktur)

More from .SE (Stiftelsen för Internetinfrastruktur) (12)

Optimera STHLM 2011 - Patrik Wallström, .SE
Optimera STHLM 2011 - Patrik Wallström, .SEOptimera STHLM 2011 - Patrik Wallström, .SE
Optimera STHLM 2011 - Patrik Wallström, .SE
 
Optimera STHLM 2011 - Måns Jonasson
Optimera STHLM 2011 - Måns JonassonOptimera STHLM 2011 - Måns Jonasson
Optimera STHLM 2011 - Måns Jonasson
 
Tobbe Eklöv
Tobbe EklövTobbe Eklöv
Tobbe Eklöv
 
Kurtis Lindqvist
Kurtis LindqvistKurtis Lindqvist
Kurtis Lindqvist
 
Kjell Leknes
Kjell LeknesKjell Leknes
Kjell Leknes
 
Claes Tagemark
Claes TagemarkClaes Tagemark
Claes Tagemark
 
Anders Örtengren
Anders ÖrtengrenAnders Örtengren
Anders Örtengren
 
OPTIMERA STHLM! Jacob Hansson
OPTIMERA STHLM! Jacob HanssonOPTIMERA STHLM! Jacob Hansson
OPTIMERA STHLM! Jacob Hansson
 
OPTIMERA STHLM! Isac Lagerblad
OPTIMERA STHLM! Isac LagerbladOPTIMERA STHLM! Isac Lagerblad
OPTIMERA STHLM! Isac Lagerblad
 
OPTIMERA STHLM! Daniel Stenberg
OPTIMERA STHLM! Daniel StenbergOPTIMERA STHLM! Daniel Stenberg
OPTIMERA STHLM! Daniel Stenberg
 
OPTIMERA STHLM! Stefan Pettersson
OPTIMERA STHLM! Stefan PetterssonOPTIMERA STHLM! Stefan Pettersson
OPTIMERA STHLM! Stefan Pettersson
 
OPTIMERA STHLM! Patrik Wallström
OPTIMERA STHLM! Patrik WallströmOPTIMERA STHLM! Patrik Wallström
OPTIMERA STHLM! Patrik Wallström
 

Recently uploaded

Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
panagenda
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
WSO2
 

Recently uploaded (20)

Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectors
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
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
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
 
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...
 
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
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challenges
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024
 
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
 

Optimera STHLM 2011 - Mikael Berggren, Spotify

  • 1. Is it Web Scale?   Mikael  Berggren   miken@spo1fy.com  
  • 2. Who  is  this  old  guy?   •  Web  Team  Lead  @  Spo1fy   •  Started  back  in  the  the  glory  days  of  2000   •  Only  works  for  companies  beginning  with  an  S   (Spray,  Stardoll  &  Spo1fy)  
  • 3. Is  /dev/null  web  scale?   “Mongo  DB  is  Web  Scale”  –  YouTube.com  
  • 4. Success  in  scale  fail   •  Choose  by  buzz  /  trends   •  Use  technology  suitable  for  something   completely  different   •  Web  frameworks   •  Don’t  measure  or  look  at  graphs  
  • 5. “We’re  using  X  and  it  scales”   •  There  is  no  magic  solu1on  that  scales  out  of   the  box   •  Choose  the  technology  you’re  familiar  with   •  Middle  bird  get’s  the  worm  
  • 6. What  is  scaling?   •  It’s  about  lying  :)   •  Take  control  of  your  code   •  Push  instead  of  pull   •  Finding  boZlenecks  and  fix  them   •  Avoid  SPoF  as  much  as  you  can   •  Measure  and  analyze  
  • 7. Cache  is  king!   •  Cache  on  mul1ple  instances   •  Cache  as  close  to  the  final  result  as  possible   •  Memcache  is  good   •  but  flat  files  is  even  beZer    
  • 8. Using  memcache   •  Local  &  Global  instances   •  Global:  For  everything  that  needs  to  be   distributed  and  synchronized   •  Local:  For  everything  else   •  Make  sure  failovers  work  correctly   •  Use  getMul1  when  possible   •  Have  several  small  instances  instead  of  one   large  
  • 9. File  cache   •  Fast  and  reliable   •  No  3rd  party  dependencies   •  Used  ocen  =>  Really  fast  access   •  Easy  to  scale   •  Atomic  updates  
  • 10. Web  frameworks?  No  thanks!   •  Never  built  for  your  specific  needs.  If  they  are,   you’re  damn  lucky  :)   •  Hard  to  control  data  and  request  handling   your  way  (plugins,  modules)   •  A  lot  of  overhead  for  each  request  
  • 11. Database  scaling   •  Do  your  homework  on  indexes  and  queries   •  Test  your  knowledge  on  indexes  and  queries   •  Use  slave  nodes  for  reads   •  Horizontal  sharding  for  segments  of  users   •  Ver1cal  sharding  for  user-­‐data  
  • 12. RDB  vs.  NoSQL   •  “No”  in  NoSQL  stands  for  “Not  Only”   •  Use  the  correct  storage  for  your  purpose   •  Don’t  do  as  Digg.com…  
  • 13. Scaling  at  Stardoll   •  >3500  dynamic  PV/s   •  Horizontal  sharding  of  user-­‐data   •  Pre-­‐genera1on  of  content   •  Measuring  render-­‐1me  for  each  page  
  • 14. Scaling  at  Spo1fy   •  We  said  “Bye  Wordpress!”  and  the  servers   where  happy  again   •  95%  of  all  content:  flat  files   •  Dependencies  on  shared  services   •  Handle  huge  spikes  in  traffic  
  • 16. Recommenda1ons   •  Have  a  code  standard  everyone  must  follow!   •  Great  error  handling  and  logging   •  Possibility  to  disable  features/func1onality   •  Try  to  do  requests  asynchronous   •  Avoid  race  condi1ons   •  Monitor,  measure  and  analyze    !important  
  • 18. And btw, we’re hiring   spo1fy.com/jobs