SlideShare uma empresa Scribd logo
1 de 32
Rapidly Developing FarmVille How we built and scaled a #1 Facebook game in 5 weeks AmittMahajan Lead Developer – FarmVille March 9, 2010
FarmVille
5 week development cycle FarmVille 6 developers (PHP/Flash) 2 artists 3 producers/designers
At Launch FarmVille 18K users/day after 24 hrs 1M users/day after 4 days
Today FarmVille 110M+ Installs  31M Players/Day
My Goals Reduce the amount of time it takes you to develop your games Give you a blueprint for how to reliably scale your games to millions without your servers falling over
What slows down developers? Other developers Design / Art Production (Copy) Lack of knowledge
Increasing Developer Efficiency Flash (Client) PHP (Server) All developers know both Design DOESN’T rule all Developers co-own features with designers
Data Driven Design Shoot for a content pipeline that doesn’t need a developer Data driven can be as easy as a designer-editable XML file No devneeded!
String Tables A string table is an external file that holds strings for the app Best practice to prepare for localization Developers are not blocked by production Allows quick response to Facebook TOS changes
Abstracted Network Layer Feature developers get client/server communication and serialization for free Goal
Abstracted Network Layer PHP Flash Feature A Feature B Feature A Service Feature B Service Networked Actions Action Dispatcher Network Layer Network Layer Validation Checks Validation Checks AMF Protocol (RPC) Action Batching Result Batching
Network Layer Batching No need to do the work twice Reduced server load in FarmVille by 50%! Server Client Only One Request onPlow() Plow Plow onPlow() Plant Plant onPlant() Plow …
Network Layer Validation Solves problem of unfiltered input Ensures data is received by server in-order it was sent
Social Network Wrapper Single place to perform Facebook API calls Working with a highly dynamic API can be difficult Abstracting FB calls makes them easier to integrate Allows for cross-platform games
Continuous Deployment Build latest version of source-repo Deploy to test “auto app” on Facebook to surface production issues early
Continuous Deployment FarmVille QA Process Auto app Staging Production Quick Smoke Full Test Pass
FarmVille Traffic Growth 1 Million DAUsevery week for 20 weeks source: developeranalytics.com
Scalable Server Architecture We had no choice but to scale on the cloud Every part of the server architecture scales horizontally No single points of failure Take the DB out of the equation
Round Robin DNS … Load Balancer #1 Load Balancer #N      Auto-scaling web      array (PHP) … Web Server #M Web Server #1 User Data  & Updates Memcache Pool Lazy Writes DB Layer Data Reads … DB-#K Master DB-#1 Master … DB-#K Slave DB-#1 Slave
All you need to implement is… … Web Server #M Web Server #1 …everything else is off-the-shelf components! …
Reducing Load-times Users want responsive pages Show something immediately Player’s won’t wait for your app to load Stream non-critical content
Avoid Remote Calls Remote server calls are slow and unreliable Aim for no remote calls during load Embed data into Javascript Facebook Iframe Inline-JS here Flash ClientEmbed
Caching Slow Calls Build in FacebookAPI caching within the social network wrapper Write a DB wrapper to generate and cache SQL
FarmVille Page Profiler Catch and eliminate all un-cached Facebook and DB calls Goal
Fault Tolerance Servers do go down randomly Build redundancy on all levels of server architecture Facebook is a dependency also Aim for DB-less & Facebook-less modes “Defcon”-style error management
Runtime Config How do we progressively keep the game running? Create all features with kill-switches Create a web dashboard to allow non-technical folks to help out
Is it still running? Notify your team when things break using server monitoring (Nagios/Munin) What to watch Server load/traffic graphs Memcacheevictions
Stats Tracking How do we know what users are seeing? Have the client send back statistics Number of errors Load-times Take a metrics driven approach to error handling
Before Launching Get confidence that your stuff actually works Perform load testing Social games are a marathon not a sprint Sleep before launching!
Questions?
Thank You!

Mais conteúdo relacionado

Mais procurados

Speed up your site! #wcmtl2015 by Meagan Hanes
Speed up your site! #wcmtl2015 by Meagan HanesSpeed up your site! #wcmtl2015 by Meagan Hanes
Speed up your site! #wcmtl2015 by Meagan HanesMeagan Hanes
 
SharePoint Saturday Cincinnati 2014 - CSOM
SharePoint Saturday Cincinnati 2014 - CSOMSharePoint Saturday Cincinnati 2014 - CSOM
SharePoint Saturday Cincinnati 2014 - CSOMRyan Dennis
 
Ryan king wp-plugin-presentation
Ryan king wp-plugin-presentationRyan king wp-plugin-presentation
Ryan king wp-plugin-presentationRyan King
 
ISBG / NCUG Why Didn't Anyone Tell Me Notes Could Do That
ISBG / NCUG Why Didn't Anyone Tell Me Notes Could Do ThatISBG / NCUG Why Didn't Anyone Tell Me Notes Could Do That
ISBG / NCUG Why Didn't Anyone Tell Me Notes Could Do ThatKeith Brooks
 
Admins Anonymous - the 5 step program for recovering Jira Admins. Atlassian S...
Admins Anonymous - the 5 step program for recovering Jira Admins. Atlassian S...Admins Anonymous - the 5 step program for recovering Jira Admins. Atlassian S...
Admins Anonymous - the 5 step program for recovering Jira Admins. Atlassian S...Cprime
 
Performance optimization of vue.js apps with modern js
Performance optimization of vue.js apps with modern jsPerformance optimization of vue.js apps with modern js
Performance optimization of vue.js apps with modern jsFilip Rakowski
 
Building Faster Locally with Local - Ben Turner
Building Faster Locally with Local - Ben TurnerBuilding Faster Locally with Local - Ben Turner
Building Faster Locally with Local - Ben TurnerWP Engine
 
Build Applications Faster with SWCs
Build Applications Faster with SWCsBuild Applications Faster with SWCs
Build Applications Faster with SWCsChris Black
 
Functional webapplicaations using fsharp and suave
Functional webapplicaations using fsharp and suaveFunctional webapplicaations using fsharp and suave
Functional webapplicaations using fsharp and suaveTomas Jansson
 
Building High Performance Web Applications
Building High Performance Web ApplicationsBuilding High Performance Web Applications
Building High Performance Web ApplicationsJeff Whelpley
 
How to Wield Kentico 9 in the Real World
How to Wield Kentico 9 in the Real WorldHow to Wield Kentico 9 in the Real World
How to Wield Kentico 9 in the Real WorldBrian McKeiver
 
Salesforce automationhour meighanbrodkeyflowcomponents
Salesforce automationhour meighanbrodkeyflowcomponentsSalesforce automationhour meighanbrodkeyflowcomponents
Salesforce automationhour meighanbrodkeyflowcomponentsMeighan Brodkey
 
Web based desktop
Web based desktopWeb based desktop
Web based desktopDoug Moncur
 
Amp up your Site with Accelerated Mobile Pages
Amp up your Site with Accelerated Mobile PagesAmp up your Site with Accelerated Mobile Pages
Amp up your Site with Accelerated Mobile PagesBrian McKeiver
 
Balsamiq Mockups: User interface screen design tool
Balsamiq Mockups: User interface screen design toolBalsamiq Mockups: User interface screen design tool
Balsamiq Mockups: User interface screen design toolNathanael Boehm
 
Introduction to Balsamiq Mockups
Introduction to Balsamiq MockupsIntroduction to Balsamiq Mockups
Introduction to Balsamiq MockupsE2LOGY
 
The WP Engine Developer Experience. Increased agility, improved efficiency.
The WP Engine Developer Experience. Increased agility, improved efficiency.The WP Engine Developer Experience. Increased agility, improved efficiency.
The WP Engine Developer Experience. Increased agility, improved efficiency.WP Engine
 

Mais procurados (20)

Speed up your site! #wcmtl2015 by Meagan Hanes
Speed up your site! #wcmtl2015 by Meagan HanesSpeed up your site! #wcmtl2015 by Meagan Hanes
Speed up your site! #wcmtl2015 by Meagan Hanes
 
SharePoint Saturday Cincinnati 2014 - CSOM
SharePoint Saturday Cincinnati 2014 - CSOMSharePoint Saturday Cincinnati 2014 - CSOM
SharePoint Saturday Cincinnati 2014 - CSOM
 
Ryan king wp-plugin-presentation
Ryan king wp-plugin-presentationRyan king wp-plugin-presentation
Ryan king wp-plugin-presentation
 
ISBG / NCUG Why Didn't Anyone Tell Me Notes Could Do That
ISBG / NCUG Why Didn't Anyone Tell Me Notes Could Do ThatISBG / NCUG Why Didn't Anyone Tell Me Notes Could Do That
ISBG / NCUG Why Didn't Anyone Tell Me Notes Could Do That
 
Admins Anonymous - the 5 step program for recovering Jira Admins. Atlassian S...
Admins Anonymous - the 5 step program for recovering Jira Admins. Atlassian S...Admins Anonymous - the 5 step program for recovering Jira Admins. Atlassian S...
Admins Anonymous - the 5 step program for recovering Jira Admins. Atlassian S...
 
Performance optimization of vue.js apps with modern js
Performance optimization of vue.js apps with modern jsPerformance optimization of vue.js apps with modern js
Performance optimization of vue.js apps with modern js
 
Scaling small apps
Scaling small appsScaling small apps
Scaling small apps
 
Windows 8
Windows 8Windows 8
Windows 8
 
Building Faster Locally with Local - Ben Turner
Building Faster Locally with Local - Ben TurnerBuilding Faster Locally with Local - Ben Turner
Building Faster Locally with Local - Ben Turner
 
Build Applications Faster with SWCs
Build Applications Faster with SWCsBuild Applications Faster with SWCs
Build Applications Faster with SWCs
 
Functional webapplicaations using fsharp and suave
Functional webapplicaations using fsharp and suaveFunctional webapplicaations using fsharp and suave
Functional webapplicaations using fsharp and suave
 
Building High Performance Web Applications
Building High Performance Web ApplicationsBuilding High Performance Web Applications
Building High Performance Web Applications
 
How to Wield Kentico 9 in the Real World
How to Wield Kentico 9 in the Real WorldHow to Wield Kentico 9 in the Real World
How to Wield Kentico 9 in the Real World
 
Salesforce automationhour meighanbrodkeyflowcomponents
Salesforce automationhour meighanbrodkeyflowcomponentsSalesforce automationhour meighanbrodkeyflowcomponents
Salesforce automationhour meighanbrodkeyflowcomponents
 
Web based desktop
Web based desktopWeb based desktop
Web based desktop
 
Amp up your Site with Accelerated Mobile Pages
Amp up your Site with Accelerated Mobile PagesAmp up your Site with Accelerated Mobile Pages
Amp up your Site with Accelerated Mobile Pages
 
Balsamiq Mockups: User interface screen design tool
Balsamiq Mockups: User interface screen design toolBalsamiq Mockups: User interface screen design tool
Balsamiq Mockups: User interface screen design tool
 
Balsamiq
BalsamiqBalsamiq
Balsamiq
 
Introduction to Balsamiq Mockups
Introduction to Balsamiq MockupsIntroduction to Balsamiq Mockups
Introduction to Balsamiq Mockups
 
The WP Engine Developer Experience. Increased agility, improved efficiency.
The WP Engine Developer Experience. Increased agility, improved efficiency.The WP Engine Developer Experience. Increased agility, improved efficiency.
The WP Engine Developer Experience. Increased agility, improved efficiency.
 

Destaque

Run and jump tutorial (part 1) actors
Run and jump tutorial (part 1)   actorsRun and jump tutorial (part 1)   actors
Run and jump tutorial (part 1) actorsMuhd Basheer
 
Facebook Strategies For The Classroom
Facebook Strategies For The ClassroomFacebook Strategies For The Classroom
Facebook Strategies For The ClassroomKevin Lim
 
1001 Game Ideas Package
1001 Game Ideas Package1001 Game Ideas Package
1001 Game Ideas Packageaakoo
 
Social Gaming Overview: Too Big To Ignore
Social Gaming Overview: Too Big To IgnoreSocial Gaming Overview: Too Big To Ignore
Social Gaming Overview: Too Big To IgnoreMark Silva
 
Creativity Techniques in Game Design
Creativity Techniques in Game DesignCreativity Techniques in Game Design
Creativity Techniques in Game Designaakoo
 
20 Game Ideas You Should Steal
20 Game Ideas You Should Steal20 Game Ideas You Should Steal
20 Game Ideas You Should StealStuart Dredge
 

Destaque (6)

Run and jump tutorial (part 1) actors
Run and jump tutorial (part 1)   actorsRun and jump tutorial (part 1)   actors
Run and jump tutorial (part 1) actors
 
Facebook Strategies For The Classroom
Facebook Strategies For The ClassroomFacebook Strategies For The Classroom
Facebook Strategies For The Classroom
 
1001 Game Ideas Package
1001 Game Ideas Package1001 Game Ideas Package
1001 Game Ideas Package
 
Social Gaming Overview: Too Big To Ignore
Social Gaming Overview: Too Big To IgnoreSocial Gaming Overview: Too Big To Ignore
Social Gaming Overview: Too Big To Ignore
 
Creativity Techniques in Game Design
Creativity Techniques in Game DesignCreativity Techniques in Game Design
Creativity Techniques in Game Design
 
20 Game Ideas You Should Steal
20 Game Ideas You Should Steal20 Game Ideas You Should Steal
20 Game Ideas You Should Steal
 

Semelhante a Rapidly Building FarmVille: How we built and scaled a #1 Facebook game in 5 weeks (GDC 2010)

web development ppt by prakash bedage
web development ppt by prakash bedageweb development ppt by prakash bedage
web development ppt by prakash bedagePrakashBedage
 
web development project prakash.pptx
web development project prakash.pptxweb development project prakash.pptx
web development project prakash.pptxPrakashBedage
 
A Quick Guide On Mobile App Backend Development For Busy People.docx
A Quick Guide On Mobile App Backend Development For Busy People.docxA Quick Guide On Mobile App Backend Development For Busy People.docx
A Quick Guide On Mobile App Backend Development For Busy People.docxgoodcoders
 
A Quick Guide On Mobile App Backend Development For Busy People.docx
A Quick Guide On Mobile App Backend Development For Busy People.docxA Quick Guide On Mobile App Backend Development For Busy People.docx
A Quick Guide On Mobile App Backend Development For Busy People.docxgoodcoders
 
TECHNOLOGY FOR BACK-END WEB DEVELOPMENT: SERVER-SIDE SCRIPTING
TECHNOLOGY FOR BACK-END WEB DEVELOPMENT: SERVER-SIDE SCRIPTING TECHNOLOGY FOR BACK-END WEB DEVELOPMENT: SERVER-SIDE SCRIPTING
TECHNOLOGY FOR BACK-END WEB DEVELOPMENT: SERVER-SIDE SCRIPTING PamRobert
 
Top 11 Front-End Web Development Tools To Consider in 2020
 Top 11 Front-End Web Development Tools To Consider in 2020 Top 11 Front-End Web Development Tools To Consider in 2020
Top 11 Front-End Web Development Tools To Consider in 2020Katy Slemon
 
Top 13 Backend Frameworks for Web development in 2024
Top 13 Backend Frameworks for Web development in 2024Top 13 Backend Frameworks for Web development in 2024
Top 13 Backend Frameworks for Web development in 2024Clarion Technologies
 
How To be a Backend developer
How To be a Backend developer    How To be a Backend developer
How To be a Backend developer Ramy Hakam
 
Cross platform engineering - Lessons Learned (Michael Asimakopoulos, Valadis ...
Cross platform engineering - Lessons Learned (Michael Asimakopoulos, Valadis ...Cross platform engineering - Lessons Learned (Michael Asimakopoulos, Valadis ...
Cross platform engineering - Lessons Learned (Michael Asimakopoulos, Valadis ...GreeceJS
 
Uncovering Windows - Silverlight Seminar
Uncovering Windows - Silverlight SeminarUncovering Windows - Silverlight Seminar
Uncovering Windows - Silverlight SeminarAbram John Limpin
 
System design for Web Application
System design for Web ApplicationSystem design for Web Application
System design for Web ApplicationMichael Choi
 
ch6. Introduction to programming languages.pptx
ch6. Introduction to programming languages.pptxch6. Introduction to programming languages.pptx
ch6. Introduction to programming languages.pptxTimmiTimmiChoice
 
App.Next - The Future of Domino Application Development
App.Next - The Future of Domino Application DevelopmentApp.Next - The Future of Domino Application Development
App.Next - The Future of Domino Application DevelopmentTeamstudio
 
An Introduction To Linux Development Environment
An Introduction To Linux Development EnvironmentAn Introduction To Linux Development Environment
An Introduction To Linux Development EnvironmentS. M. Hossein Hamidi
 

Semelhante a Rapidly Building FarmVille: How we built and scaled a #1 Facebook game in 5 weeks (GDC 2010) (20)

web development ppt by prakash bedage
web development ppt by prakash bedageweb development ppt by prakash bedage
web development ppt by prakash bedage
 
web development project prakash.pptx
web development project prakash.pptxweb development project prakash.pptx
web development project prakash.pptx
 
Social Network
Social NetworkSocial Network
Social Network
 
test4
test4test4
test4
 
Web
WebWeb
Web
 
test4
test4test4
test4
 
test3
test3test3
test3
 
A Quick Guide On Mobile App Backend Development For Busy People.docx
A Quick Guide On Mobile App Backend Development For Busy People.docxA Quick Guide On Mobile App Backend Development For Busy People.docx
A Quick Guide On Mobile App Backend Development For Busy People.docx
 
A Quick Guide On Mobile App Backend Development For Busy People.docx
A Quick Guide On Mobile App Backend Development For Busy People.docxA Quick Guide On Mobile App Backend Development For Busy People.docx
A Quick Guide On Mobile App Backend Development For Busy People.docx
 
TECHNOLOGY FOR BACK-END WEB DEVELOPMENT: SERVER-SIDE SCRIPTING
TECHNOLOGY FOR BACK-END WEB DEVELOPMENT: SERVER-SIDE SCRIPTING TECHNOLOGY FOR BACK-END WEB DEVELOPMENT: SERVER-SIDE SCRIPTING
TECHNOLOGY FOR BACK-END WEB DEVELOPMENT: SERVER-SIDE SCRIPTING
 
Top 11 Front-End Web Development Tools To Consider in 2020
 Top 11 Front-End Web Development Tools To Consider in 2020 Top 11 Front-End Web Development Tools To Consider in 2020
Top 11 Front-End Web Development Tools To Consider in 2020
 
Top 13 Backend Frameworks for Web development in 2024
Top 13 Backend Frameworks for Web development in 2024Top 13 Backend Frameworks for Web development in 2024
Top 13 Backend Frameworks for Web development in 2024
 
How To be a Backend developer
How To be a Backend developer    How To be a Backend developer
How To be a Backend developer
 
Cross platform engineering - Lessons Learned (Michael Asimakopoulos, Valadis ...
Cross platform engineering - Lessons Learned (Michael Asimakopoulos, Valadis ...Cross platform engineering - Lessons Learned (Michael Asimakopoulos, Valadis ...
Cross platform engineering - Lessons Learned (Michael Asimakopoulos, Valadis ...
 
Uncovering Windows - Silverlight Seminar
Uncovering Windows - Silverlight SeminarUncovering Windows - Silverlight Seminar
Uncovering Windows - Silverlight Seminar
 
System design for Web Application
System design for Web ApplicationSystem design for Web Application
System design for Web Application
 
ch6. Introduction to programming languages.pptx
ch6. Introduction to programming languages.pptxch6. Introduction to programming languages.pptx
ch6. Introduction to programming languages.pptx
 
App.Next - The Future of Domino Application Development
App.Next - The Future of Domino Application DevelopmentApp.Next - The Future of Domino Application Development
App.Next - The Future of Domino Application Development
 
An Introduction To Linux Development Environment
An Introduction To Linux Development EnvironmentAn Introduction To Linux Development Environment
An Introduction To Linux Development Environment
 
Flex And Php 101
Flex And Php 101Flex And Php 101
Flex And Php 101
 

Último

Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)wesley chun
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CVKhem
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdflior mazor
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024The Digital Insurer
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 
Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessPixlogix Infotech
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...DianaGray10
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
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.pdfsudhanshuwaghmare1
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘RTylerCroy
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Scriptwesley chun
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsJoaquim Jorge
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Enterprise Knowledge
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfhans926745
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUK Journal
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 

Último (20)

Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your Business
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
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
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdf
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 

Rapidly Building FarmVille: How we built and scaled a #1 Facebook game in 5 weeks (GDC 2010)

  • 1. Rapidly Developing FarmVille How we built and scaled a #1 Facebook game in 5 weeks AmittMahajan Lead Developer – FarmVille March 9, 2010
  • 3. 5 week development cycle FarmVille 6 developers (PHP/Flash) 2 artists 3 producers/designers
  • 4. At Launch FarmVille 18K users/day after 24 hrs 1M users/day after 4 days
  • 5. Today FarmVille 110M+ Installs 31M Players/Day
  • 6. My Goals Reduce the amount of time it takes you to develop your games Give you a blueprint for how to reliably scale your games to millions without your servers falling over
  • 7. What slows down developers? Other developers Design / Art Production (Copy) Lack of knowledge
  • 8. Increasing Developer Efficiency Flash (Client) PHP (Server) All developers know both Design DOESN’T rule all Developers co-own features with designers
  • 9. Data Driven Design Shoot for a content pipeline that doesn’t need a developer Data driven can be as easy as a designer-editable XML file No devneeded!
  • 10. String Tables A string table is an external file that holds strings for the app Best practice to prepare for localization Developers are not blocked by production Allows quick response to Facebook TOS changes
  • 11. Abstracted Network Layer Feature developers get client/server communication and serialization for free Goal
  • 12. Abstracted Network Layer PHP Flash Feature A Feature B Feature A Service Feature B Service Networked Actions Action Dispatcher Network Layer Network Layer Validation Checks Validation Checks AMF Protocol (RPC) Action Batching Result Batching
  • 13. Network Layer Batching No need to do the work twice Reduced server load in FarmVille by 50%! Server Client Only One Request onPlow() Plow Plow onPlow() Plant Plant onPlant() Plow …
  • 14. Network Layer Validation Solves problem of unfiltered input Ensures data is received by server in-order it was sent
  • 15. Social Network Wrapper Single place to perform Facebook API calls Working with a highly dynamic API can be difficult Abstracting FB calls makes them easier to integrate Allows for cross-platform games
  • 16. Continuous Deployment Build latest version of source-repo Deploy to test “auto app” on Facebook to surface production issues early
  • 17. Continuous Deployment FarmVille QA Process Auto app Staging Production Quick Smoke Full Test Pass
  • 18. FarmVille Traffic Growth 1 Million DAUsevery week for 20 weeks source: developeranalytics.com
  • 19. Scalable Server Architecture We had no choice but to scale on the cloud Every part of the server architecture scales horizontally No single points of failure Take the DB out of the equation
  • 20. Round Robin DNS … Load Balancer #1 Load Balancer #N Auto-scaling web array (PHP) … Web Server #M Web Server #1 User Data & Updates Memcache Pool Lazy Writes DB Layer Data Reads … DB-#K Master DB-#1 Master … DB-#K Slave DB-#1 Slave
  • 21. All you need to implement is… … Web Server #M Web Server #1 …everything else is off-the-shelf components! …
  • 22. Reducing Load-times Users want responsive pages Show something immediately Player’s won’t wait for your app to load Stream non-critical content
  • 23. Avoid Remote Calls Remote server calls are slow and unreliable Aim for no remote calls during load Embed data into Javascript Facebook Iframe Inline-JS here Flash ClientEmbed
  • 24. Caching Slow Calls Build in FacebookAPI caching within the social network wrapper Write a DB wrapper to generate and cache SQL
  • 25. FarmVille Page Profiler Catch and eliminate all un-cached Facebook and DB calls Goal
  • 26. Fault Tolerance Servers do go down randomly Build redundancy on all levels of server architecture Facebook is a dependency also Aim for DB-less & Facebook-less modes “Defcon”-style error management
  • 27. Runtime Config How do we progressively keep the game running? Create all features with kill-switches Create a web dashboard to allow non-technical folks to help out
  • 28. Is it still running? Notify your team when things break using server monitoring (Nagios/Munin) What to watch Server load/traffic graphs Memcacheevictions
  • 29. Stats Tracking How do we know what users are seeing? Have the client send back statistics Number of errors Load-times Take a metrics driven approach to error handling
  • 30. Before Launching Get confidence that your stuff actually works Perform load testing Social games are a marathon not a sprint Sleep before launching!