SlideShare a Scribd company logo
1 of 60
Download to read offline
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




               Your Language Doesn't Scale
               A Discussion of the Nature of Scaling

               Ikai Lan
               Linkedin




Ikai Lan — Your Language Doesn’t Scale                                Slide 1
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                Hi! I’m Ikai Lan




Ikai Lan — Your Language Doesn’t Scale                                Slide 2
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                This talk is about scaling




Ikai Lan — Your Language Doesn’t Scale                                Slide 3
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin



                Particularly with regards to the
                web




Ikai Lan — Your Language Doesn’t Scale                                Slide 4
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                Attributes of a web app
       Client pull based
       Operations must finish “fast”
       “Fresh” information




Ikai Lan — Your Language Doesn’t Scale                                Slide 5
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                The chip on my shoulder




Ikai Lan — Your Language Doesn’t Scale                                Slide 6
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                Ruby on Rails can’t scale!
       Ruby is slow
       Default SQL used is not optimal
       Page rendering is slow




Ikai Lan — Your Language Doesn’t Scale                                Slide 7
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                All of these are true




Ikai Lan — Your Language Doesn’t Scale                                Slide 8
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                1. Ruby is slow




Ikai Lan — Your Language Doesn’t Scale                                Slide 9
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                2. SQL used is not optimal




Ikai Lan — Your Language Doesn’t Scale                               Slide 10
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                3. Rendering is slow

           I don’t have a clever picture here.
                Just take my word for it.




Ikai Lan — Your Language Doesn’t Scale                               Slide 11
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                Why do these fall flat?




Ikai Lan — Your Language Doesn’t Scale                               Slide 12
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




             Scaling != efficiency




Ikai Lan — Your Language Doesn’t Scale                               Slide 13
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                Efficiency is
       Minimizing input for
       output

       Bang for your buck




Ikai Lan — Your Language Doesn’t Scale                               Slide 14
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                Scaling != performance




Ikai Lan — Your Language Doesn’t Scale                               Slide 15
Colorado Software Summit: October 19 – 24, 2008              © Copyright 2008, Linkedin




                Performance is
                                                  Maximizing output
                                                  for some input

                                                  Speed




Ikai Lan — Your Language Doesn’t Scale                                          Slide 16
Colorado Software Summit: October 19 – 24, 2008               © Copyright 2008, Linkedin




                Scalability is
                                                  Being able to grow
                                                  capacity with
                                                  demand

                                                  How well a solution
                                                  to some problem
                                                  will work when the
                                                  size of the problem
                                                  increases


Ikai Lan — Your Language Doesn’t Scale                                           Slide 17
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                In an ideal world …


          We achieve scalability
       efficiently while maintaining
               performance


Ikai Lan — Your Language Doesn’t Scale                               Slide 18
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




         Myth: Needing to throw
         hardware to solve a
         capacity problem means
         your application is not
         scalable


Ikai Lan — Your Language Doesn’t Scale                               Slide 19
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




          Truth: If this works, by
          the definition, your
          application IS scalable



Ikai Lan — Your Language Doesn’t Scale                               Slide 20
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                … maybe not efficient




Ikai Lan — Your Language Doesn’t Scale                               Slide 21
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                So the arguments …

       Ruby is slow
       Default SQL is not
       optimal
       Page rendering is
       slow




Ikai Lan — Your Language Doesn’t Scale                               Slide 22
Colorado Software Summit: October 19 – 24, 2008    © Copyright 2008, Linkedin




                Concerning performance …


                                                  Assets
                Internet
                User




                           Browser
                                                  Database
Ikai Lan — Your Language Doesn’t Scale                                Slide 23
Colorado Software Summit: October 19 – 24, 2008                     © Copyright 2008, Linkedin




                How much time?


                                                                  Assets
                Internet
                User                                             Tiny fraction



                                                  Network: ???

                           Rendering: LONG TIME
                                                                 LONG TIME
Ikai Lan — Your Language Doesn’t Scale                                                 Slide 24
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                Scaling case study




Ikai Lan — Your Language Doesn’t Scale                               Slide 25
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




               First let’s define terms




Ikai Lan — Your Language Doesn’t Scale                               Slide 26
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                Vertical scaling

       Improving
       performance in one
       of our component
       tiers

       Adding a tier
       optimized for some
       portion of the load


Ikai Lan — Your Language Doesn’t Scale                               Slide 27
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                Vertical scaling examples

       Upgrading hardware
       Edge caching
       Adding a caching tier for the data store




Ikai Lan — Your Language Doesn’t Scale                               Slide 28
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                Horizontal scaling

       Increase capacity by
       increasing instances
       of components

       Spreading load
       across instances




Ikai Lan — Your Language Doesn’t Scale                               Slide 29
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                Horizontal scaling examples

       Load balancing (hardware LB or DNS
       load balancing)
       Data partitioning




Ikai Lan — Your Language Doesn’t Scale                               Slide 30
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                Different strokes …




Ikai Lan — Your Language Doesn’t Scale                               Slide 31
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




          On to the case study!




Ikai Lan — Your Language Doesn’t Scale                               Slide 32
Colorado Software Summit: October 19 – 24, 2008          © Copyright 2008, Linkedin




                These guys made a site




                                   Matt           Ikai


Ikai Lan — Your Language Doesn’t Scale                                      Slide 33
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                To share pictures!




Ikai Lan — Your Language Doesn’t Scale                               Slide 34
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                Our first architecture




Ikai Lan — Your Language Doesn’t Scale                               Slide 35
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                Awesome! We have users!




Ikai Lan — Your Language Doesn’t Scale                               Slide 36
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                We have too many users!




Ikai Lan — Your Language Doesn’t Scale                               Slide 37
Colorado Software Summit: October 19 – 24, 2008                    © Copyright 2008, Linkedin




                The yelling begins
                                                  Dude! Add more
                                                     hardware!




                        You don’t think I tried?
                        The hardware - it does
                               nothing!




Ikai Lan — Your Language Doesn’t Scale                                                Slide 38
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                Our current architecture




Ikai Lan — Your Language Doesn’t Scale                               Slide 39
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                Why isn’t this working?




Ikai Lan — Your Language Doesn’t Scale                               Slide 40
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                Bottlenecks! Bottlenecks!




Ikai Lan — Your Language Doesn’t Scale                               Slide 41
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                The first bottleneck is always the
                persistent store




Ikai Lan — Your Language Doesn’t Scale                               Slide 42
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                Solution: Replicate data




Ikai Lan — Your Language Doesn’t Scale                               Slide 43
Colorado Software Summit: October 19 – 24, 2008                            © Copyright 2008, Linkedin




                New problem: replication delay


                                                    How come everything I do
                                                  takes a few minutes to work?




Ikai Lan — Your Language Doesn’t Scale                                                        Slide 44
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                Solution: caching




Ikai Lan — Your Language Doesn’t Scale                               Slide 45
Colorado Software Summit: October 19 – 24, 2008     © Copyright 2008, Linkedin




                New problem: stale data


                         I can’t remove this tag!
                       Sometimes things aren’t up
                                  to date!




Ikai Lan — Your Language Doesn’t Scale                                 Slide 46
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




      So now we’ve spent all that
      engineering effort and added
      no new functionality
          (would have been a lot harder if we
          were also trying to add features to
          stay competitive)


Ikai Lan — Your Language Doesn’t Scale                               Slide 47
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                Are we done? Maybe …




Ikai Lan — Your Language Doesn’t Scale                               Slide 48
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




        More growth: all
        persistence operations are
        expensive




Ikai Lan — Your Language Doesn’t Scale                               Slide 49
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




               Have to partition DB




Ikai Lan — Your Language Doesn’t Scale                               Slide 50
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




            Our application has to now
            understand how to speak
            to a partitioned store




Ikai Lan — Your Language Doesn’t Scale                               Slide 51
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                This is really hard!




Ikai Lan — Your Language Doesn’t Scale                               Slide 52
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




            And I haven’t even gotten
            to transactional integrity
            or backups



Ikai Lan — Your Language Doesn’t Scale                               Slide 53
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




         We’re also introducing
         many more points of
         failure = ops burden




Ikai Lan — Your Language Doesn’t Scale                               Slide 54
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                Engineering problems

              Cross functional development
              Merging
              Regression testing




Ikai Lan — Your Language Doesn’t Scale                               Slide 55
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                Things now cost too much!




Ikai Lan — Your Language Doesn’t Scale                               Slide 56
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin



                Do we even have a business
                model?




Ikai Lan — Your Language Doesn’t Scale                               Slide 57
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                No one is spared!




Ikai Lan — Your Language Doesn’t Scale                               Slide 58
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                Questions?




Ikai Lan — Your Language Doesn’t Scale                               Slide 59
Colorado Software Summit: October 19 – 24, 2008   © Copyright 2008, Linkedin




                Thanks for coming!
       ilan@linkedin.com
       http://www.linkedin.com/in/ikailan




Ikai Lan — Your Language Doesn’t Scale                               Slide 60

More Related Content

More from ikailan

2011 aug-gdd-mexico-city-high-replication-datastore
2011 aug-gdd-mexico-city-high-replication-datastore2011 aug-gdd-mexico-city-high-replication-datastore
2011 aug-gdd-mexico-city-high-replication-datastoreikailan
 
2011 july-nyc-gtug-go
2011 july-nyc-gtug-go2011 july-nyc-gtug-go
2011 july-nyc-gtug-goikailan
 
2011 july-gtug-high-replication-datastore
2011 july-gtug-high-replication-datastore2011 july-gtug-high-replication-datastore
2011 july-gtug-high-replication-datastoreikailan
 
2011 june-kuala-lumpur-gtug-hackathon
2011 june-kuala-lumpur-gtug-hackathon2011 june-kuala-lumpur-gtug-hackathon
2011 june-kuala-lumpur-gtug-hackathonikailan
 
2011 June - Singapore GTUG presentation. App Engine program update + intro to Go
2011 June - Singapore GTUG presentation. App Engine program update + intro to Go2011 June - Singapore GTUG presentation. App Engine program update + intro to Go
2011 June - Singapore GTUG presentation. App Engine program update + intro to Goikailan
 
Rapid web development using tornado web and mongodb
Rapid web development using tornado web and mongodbRapid web development using tornado web and mongodb
Rapid web development using tornado web and mongodbikailan
 
Introducing the App Engine datastore
Introducing the App Engine datastoreIntroducing the App Engine datastore
Introducing the App Engine datastoreikailan
 
What is App Engine? O
What is App Engine? OWhat is App Engine? O
What is App Engine? Oikailan
 
OSCON Google App Engine Codelab - July 2010
OSCON Google App Engine Codelab - July 2010OSCON Google App Engine Codelab - July 2010
OSCON Google App Engine Codelab - July 2010ikailan
 

More from ikailan (9)

2011 aug-gdd-mexico-city-high-replication-datastore
2011 aug-gdd-mexico-city-high-replication-datastore2011 aug-gdd-mexico-city-high-replication-datastore
2011 aug-gdd-mexico-city-high-replication-datastore
 
2011 july-nyc-gtug-go
2011 july-nyc-gtug-go2011 july-nyc-gtug-go
2011 july-nyc-gtug-go
 
2011 july-gtug-high-replication-datastore
2011 july-gtug-high-replication-datastore2011 july-gtug-high-replication-datastore
2011 july-gtug-high-replication-datastore
 
2011 june-kuala-lumpur-gtug-hackathon
2011 june-kuala-lumpur-gtug-hackathon2011 june-kuala-lumpur-gtug-hackathon
2011 june-kuala-lumpur-gtug-hackathon
 
2011 June - Singapore GTUG presentation. App Engine program update + intro to Go
2011 June - Singapore GTUG presentation. App Engine program update + intro to Go2011 June - Singapore GTUG presentation. App Engine program update + intro to Go
2011 June - Singapore GTUG presentation. App Engine program update + intro to Go
 
Rapid web development using tornado web and mongodb
Rapid web development using tornado web and mongodbRapid web development using tornado web and mongodb
Rapid web development using tornado web and mongodb
 
Introducing the App Engine datastore
Introducing the App Engine datastoreIntroducing the App Engine datastore
Introducing the App Engine datastore
 
What is App Engine? O
What is App Engine? OWhat is App Engine? O
What is App Engine? O
 
OSCON Google App Engine Codelab - July 2010
OSCON Google App Engine Codelab - July 2010OSCON Google App Engine Codelab - July 2010
OSCON Google App Engine Codelab - July 2010
 

Recently uploaded

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
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxKatpro Technologies
 
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...apidays
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
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
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptxHampshireHUG
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEarley Information Science
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
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
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...Neo4j
 
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 RobisonAnna Loughnan Colquhoun
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slidevu2urc
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfEnterprise Knowledge
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Allon Mureinik
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j
 

Recently uploaded (20)

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
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
 
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...
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
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
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
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
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
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
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)
 
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
 

Ikai Lan's Discussion on Scaling Web Applications

  • 1. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Your Language Doesn't Scale A Discussion of the Nature of Scaling Ikai Lan Linkedin Ikai Lan — Your Language Doesn’t Scale Slide 1
  • 2. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Hi! I’m Ikai Lan Ikai Lan — Your Language Doesn’t Scale Slide 2
  • 3. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin This talk is about scaling Ikai Lan — Your Language Doesn’t Scale Slide 3
  • 4. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Particularly with regards to the web Ikai Lan — Your Language Doesn’t Scale Slide 4
  • 5. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Attributes of a web app Client pull based Operations must finish “fast” “Fresh” information Ikai Lan — Your Language Doesn’t Scale Slide 5
  • 6. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin The chip on my shoulder Ikai Lan — Your Language Doesn’t Scale Slide 6
  • 7. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Ruby on Rails can’t scale! Ruby is slow Default SQL used is not optimal Page rendering is slow Ikai Lan — Your Language Doesn’t Scale Slide 7
  • 8. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin All of these are true Ikai Lan — Your Language Doesn’t Scale Slide 8
  • 9. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin 1. Ruby is slow Ikai Lan — Your Language Doesn’t Scale Slide 9
  • 10. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin 2. SQL used is not optimal Ikai Lan — Your Language Doesn’t Scale Slide 10
  • 11. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin 3. Rendering is slow I don’t have a clever picture here. Just take my word for it. Ikai Lan — Your Language Doesn’t Scale Slide 11
  • 12. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Why do these fall flat? Ikai Lan — Your Language Doesn’t Scale Slide 12
  • 13. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Scaling != efficiency Ikai Lan — Your Language Doesn’t Scale Slide 13
  • 14. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Efficiency is Minimizing input for output Bang for your buck Ikai Lan — Your Language Doesn’t Scale Slide 14
  • 15. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Scaling != performance Ikai Lan — Your Language Doesn’t Scale Slide 15
  • 16. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Performance is Maximizing output for some input Speed Ikai Lan — Your Language Doesn’t Scale Slide 16
  • 17. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Scalability is Being able to grow capacity with demand How well a solution to some problem will work when the size of the problem increases Ikai Lan — Your Language Doesn’t Scale Slide 17
  • 18. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin In an ideal world … We achieve scalability efficiently while maintaining performance Ikai Lan — Your Language Doesn’t Scale Slide 18
  • 19. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Myth: Needing to throw hardware to solve a capacity problem means your application is not scalable Ikai Lan — Your Language Doesn’t Scale Slide 19
  • 20. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Truth: If this works, by the definition, your application IS scalable Ikai Lan — Your Language Doesn’t Scale Slide 20
  • 21. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin … maybe not efficient Ikai Lan — Your Language Doesn’t Scale Slide 21
  • 22. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin So the arguments … Ruby is slow Default SQL is not optimal Page rendering is slow Ikai Lan — Your Language Doesn’t Scale Slide 22
  • 23. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Concerning performance … Assets Internet User Browser Database Ikai Lan — Your Language Doesn’t Scale Slide 23
  • 24. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin How much time? Assets Internet User Tiny fraction Network: ??? Rendering: LONG TIME LONG TIME Ikai Lan — Your Language Doesn’t Scale Slide 24
  • 25. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Scaling case study Ikai Lan — Your Language Doesn’t Scale Slide 25
  • 26. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin First let’s define terms Ikai Lan — Your Language Doesn’t Scale Slide 26
  • 27. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Vertical scaling Improving performance in one of our component tiers Adding a tier optimized for some portion of the load Ikai Lan — Your Language Doesn’t Scale Slide 27
  • 28. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Vertical scaling examples Upgrading hardware Edge caching Adding a caching tier for the data store Ikai Lan — Your Language Doesn’t Scale Slide 28
  • 29. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Horizontal scaling Increase capacity by increasing instances of components Spreading load across instances Ikai Lan — Your Language Doesn’t Scale Slide 29
  • 30. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Horizontal scaling examples Load balancing (hardware LB or DNS load balancing) Data partitioning Ikai Lan — Your Language Doesn’t Scale Slide 30
  • 31. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Different strokes … Ikai Lan — Your Language Doesn’t Scale Slide 31
  • 32. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin On to the case study! Ikai Lan — Your Language Doesn’t Scale Slide 32
  • 33. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin These guys made a site Matt Ikai Ikai Lan — Your Language Doesn’t Scale Slide 33
  • 34. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin To share pictures! Ikai Lan — Your Language Doesn’t Scale Slide 34
  • 35. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Our first architecture Ikai Lan — Your Language Doesn’t Scale Slide 35
  • 36. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Awesome! We have users! Ikai Lan — Your Language Doesn’t Scale Slide 36
  • 37. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin We have too many users! Ikai Lan — Your Language Doesn’t Scale Slide 37
  • 38. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin The yelling begins Dude! Add more hardware! You don’t think I tried? The hardware - it does nothing! Ikai Lan — Your Language Doesn’t Scale Slide 38
  • 39. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Our current architecture Ikai Lan — Your Language Doesn’t Scale Slide 39
  • 40. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Why isn’t this working? Ikai Lan — Your Language Doesn’t Scale Slide 40
  • 41. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Bottlenecks! Bottlenecks! Ikai Lan — Your Language Doesn’t Scale Slide 41
  • 42. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin The first bottleneck is always the persistent store Ikai Lan — Your Language Doesn’t Scale Slide 42
  • 43. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Solution: Replicate data Ikai Lan — Your Language Doesn’t Scale Slide 43
  • 44. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin New problem: replication delay How come everything I do takes a few minutes to work? Ikai Lan — Your Language Doesn’t Scale Slide 44
  • 45. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Solution: caching Ikai Lan — Your Language Doesn’t Scale Slide 45
  • 46. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin New problem: stale data I can’t remove this tag! Sometimes things aren’t up to date! Ikai Lan — Your Language Doesn’t Scale Slide 46
  • 47. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin So now we’ve spent all that engineering effort and added no new functionality (would have been a lot harder if we were also trying to add features to stay competitive) Ikai Lan — Your Language Doesn’t Scale Slide 47
  • 48. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Are we done? Maybe … Ikai Lan — Your Language Doesn’t Scale Slide 48
  • 49. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin More growth: all persistence operations are expensive Ikai Lan — Your Language Doesn’t Scale Slide 49
  • 50. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Have to partition DB Ikai Lan — Your Language Doesn’t Scale Slide 50
  • 51. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Our application has to now understand how to speak to a partitioned store Ikai Lan — Your Language Doesn’t Scale Slide 51
  • 52. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin This is really hard! Ikai Lan — Your Language Doesn’t Scale Slide 52
  • 53. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin And I haven’t even gotten to transactional integrity or backups Ikai Lan — Your Language Doesn’t Scale Slide 53
  • 54. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin We’re also introducing many more points of failure = ops burden Ikai Lan — Your Language Doesn’t Scale Slide 54
  • 55. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Engineering problems Cross functional development Merging Regression testing Ikai Lan — Your Language Doesn’t Scale Slide 55
  • 56. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Things now cost too much! Ikai Lan — Your Language Doesn’t Scale Slide 56
  • 57. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Do we even have a business model? Ikai Lan — Your Language Doesn’t Scale Slide 57
  • 58. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin No one is spared! Ikai Lan — Your Language Doesn’t Scale Slide 58
  • 59. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Questions? Ikai Lan — Your Language Doesn’t Scale Slide 59
  • 60. Colorado Software Summit: October 19 – 24, 2008 © Copyright 2008, Linkedin Thanks for coming! ilan@linkedin.com http://www.linkedin.com/in/ikailan Ikai Lan — Your Language Doesn’t Scale Slide 60