SlideShare une entreprise Scribd logo
1  sur  44
The NEED FOR SPEED on WEB! Vijay Rayapati Product@GizaPage  @amnigos
Note : Do follow barcamp Rules!
                       Performance Tuning Your Web Apps Why SPEED matters?
The most impatient creature on the earth 
RecentlyFred Wilson spoke about
RecentlyFred Wilson spoke about And the first GOLDEN rule is SPEED
If VC’s are talking about WEB apps SPEED                                that means the problem is mainstream
What SPEED means for WEB? Facebook created PHP HipHop to speedup=F****ing 50% savings! Web would have been a great place if everything worked like a Google Instant Lot’s of bad PR and Loose users!  Tip : Do join us at Facebook Developer Garage Bangalore on 24th, September for indepth discussion on HipHop.
But Why You Should Worry? because It is about User Experience and Engagement Slow = High Bounce Rates = No users  Average users are mostly likely to quit a slow page than geeks It affects your SEO – think Google Instant but IRCTC still works in India 
 AND… Only DOGS can sleep while pages are loading 
 AND… When was the last time you were waiting for the page to load without cursing it?
What’s a Good Page Speed? F**K this Page 10 seconds SPEEED is not a feature, it’s a KILLER! 5 seconds 2.5  seconds Google loads in 823 milliseconds* * : Yotta report
God once said SPEED first EVERYTHING next * : Whom should I quote here? 
Lot’s of sites suck on the WEB!
And it’s sick to use so many lousy pages
Hey Talk is cheap…Show me the code…
Murphy's Law is usually more applicable than Moore's Law Premature optimization is the root cause of all evils - Knuth
What Should I Do to SPEED UP? Lets optimize JAVA/.NET/PHP CODE  = FUCK it I think APACHE is better than IIS = FUCK it Lets get Intel XYZ7 processor  = FUCK it Lets move to Cloud   =  FUCK It
The 80-20 Rule Let’s not worry much Problem is HERE To Speed Up To Scale Up
What Browsers do? Note : From big brother MS IE Blog!
The Birth and Death of a Page Note : Thanks to Steven Stefanov for this beauty
Note : From big brother MS IE Blog!
And the browser woes… Number of connections per host = every browser does it’s own way! Maximum numberof connections from browser. JavaScriptengines suck! So many cool effects – I need more JAVASCRIPT HTTP was built in B.C and we need SPEEDY! Enough  SHIT lets get to the POINT >>
Good news – lot’s of tools Page Speed Speed Tracer Y slow Firebug Webpage SpeedTest Dynatrace Ajax  and many more are there!
The Golden Rules 1. Do LESS :  Reduce HTTP requests – combine JS files, CSS files, Use Image Sprites 2. Do SMALL : Smush.it/PNG Crush Images, Minify JS/CSS, Remove fugly code 3. Do COOL : Cache JS/CSS/Images, Google  “optimize” options for your server  4. Do MORE : Parallel connections, Order your stuff,  Unblock JS & Use Google ajax libs 5. Do GEEKY :   XHR use JSON, Flush() early, Gzip, Dump Etags,  Cache on Server & CDN  6. Do SMART:  Lazy load, Upgrade your JS libs, Cleanup JS files & Get of rid of                            comments/code – the EVIL Tell me other 4 rules 
Thumb Rulesfor 90%  Use Google Closure Compiler – easiest way to optimize your JS. Play with Cuzillionto learn how to order Images, inline/external  Javascripts/CSS Upgrade your jQuery/others libs regularly – faster and less memory Do basic optimization of your JS code, just google – ton of resources
Thumb Rulesfor 90%  Don’t put JS libraries on your server unless required – Use Google or MS public CDN’s Burst the Cache on updates – use ? or include versioning in build script Use SpritesMeand learn image sprites – saves you a ton of  load. Lazy load/Pre-fetch if have too much stuff after page load or anticipate next page –                                      XHR, JSON : Love jQuery
If you have just wordpress Try one of those cache plug-ins like w3-total-cache
Why you should focus on ordering your stuff?
Increase Parallel Downloads Note : Too many hosts will end up with DNS look up overhead
How to do Async JS loading? RequireJS– Awesome way to load JS async and also handle dependencies
How to Measure Ajax actions? Dynatrace Ajax – If John Resig is impressed then you should also be 
How to Measure Ajax actions? Chrome Speed Tracer – This is a kick-ass 
How to Measure Ajax actions? Chrome Speed Tracer – This is a kick-ass 
Geeky: How to do JS payload split? Why load all the JS code upfront when you only need some of it? Doloto - http://msdn.microsoft.com/en-us/devlabs/ee423534.aspx
Word of caution A/B and Multivariate scripts will have impact on performance Choose user screen captures tools carefully – can get really sluggish Get rid of asp.net ajax libs, bloated and lousy! Choose your social or JS framework plug-ins carefully – most are lousy! and Look at your server logs – gives you ton of data on requests/responses Do backend profiling – if you have high loads on the system
When NOT to optimize?
The Future looks brighter! Web workers – run multiple JS threads! Hardware acceleration in Browsers – faster rendering/scaling/layouts The awesome HTML 5 –  Async/Defer, local storage/app cache, Web SQL & more! Expect better JS engines – run highly optimized and native vm code May be SPEEDY/Web Resource Bundles Soon!
Hope All Browsers will have auto update, love you Chrome! Can we do something for IE 6? – the death funerals haven’t worked yet 
Follow Leaders The Yahoo Developer Network Performance Section Google Performance  Engineering Site Steve Souders((@souders) Facebook Engineering Blog Performance Planet John Resig High Scalability InfoQ Nicole Sullivan(@stubbornella) Phillip Tellis((@bluesmoon))
Let’s make WEB faster! May god bless the speed Vijay Rayapati Product@GizaPage  @amnigos
Few last things Thanks to friends at #BCB9 Sponsorship!
Credits It’s due wherever I used images from Flickr CC, FindIcons.com  and Google Images Search  Thanks to Pallav (FusionCharts ) for the background theme.

Contenu connexe

Tendances

HTML5 CSS3 The Future of Web Technologies
HTML5 CSS3 The Future of Web TechnologiesHTML5 CSS3 The Future of Web Technologies
HTML5 CSS3 The Future of Web Technologies
hoctudau
 
The image problem of the web and how to solve it…
The image problem of the web and how to solve it…The image problem of the web and how to solve it…
The image problem of the web and how to solve it…
Christian Heilmann
 
Prabhanjan Panigrahi
Prabhanjan PanigrahiPrabhanjan Panigrahi
Prabhanjan Panigrahi
Anirban Saha
 
Raiders of the Fast Start: Frontend Performance Archaeology - Performance.now...
Raiders of the Fast Start: Frontend Performance Archaeology - Performance.now...Raiders of the Fast Start: Frontend Performance Archaeology - Performance.now...
Raiders of the Fast Start: Frontend Performance Archaeology - Performance.now...
Katie Sylor-Miller
 

Tendances (19)

HTML5 CSS3 The Future of Web Technologies
HTML5 CSS3 The Future of Web TechnologiesHTML5 CSS3 The Future of Web Technologies
HTML5 CSS3 The Future of Web Technologies
 
Dynamic website
Dynamic websiteDynamic website
Dynamic website
 
Breaking out of the Tetris mind set #btconf
Breaking out of the Tetris mind set #btconfBreaking out of the Tetris mind set #btconf
Breaking out of the Tetris mind set #btconf
 
Preparing For The Flood. How Do You Conduct Load Testing To Ready Your WordPr...
Preparing For The Flood. How Do You Conduct Load Testing To Ready Your WordPr...Preparing For The Flood. How Do You Conduct Load Testing To Ready Your WordPr...
Preparing For The Flood. How Do You Conduct Load Testing To Ready Your WordPr...
 
Erase and Rewind - Open Web Camp 2015
Erase and Rewind - Open Web Camp 2015Erase and Rewind - Open Web Camp 2015
Erase and Rewind - Open Web Camp 2015
 
Mobile Web Speed Bumps
Mobile Web Speed BumpsMobile Web Speed Bumps
Mobile Web Speed Bumps
 
The image problem of the web and how to solve it…
The image problem of the web and how to solve it…The image problem of the web and how to solve it…
The image problem of the web and how to solve it…
 
CSS vs. JavaScript - Trust vs. Control
CSS vs. JavaScript - Trust vs. ControlCSS vs. JavaScript - Trust vs. Control
CSS vs. JavaScript - Trust vs. Control
 
The State of the Web - Helsinki meetup
The State of the Web - Helsinki meetupThe State of the Web - Helsinki meetup
The State of the Web - Helsinki meetup
 
Leveling up your JavaScipt - DrupalJam 2017
Leveling up your JavaScipt - DrupalJam 2017Leveling up your JavaScipt - DrupalJam 2017
Leveling up your JavaScipt - DrupalJam 2017
 
TechSEO Boost 2021 - The Future Is The Past: Tagging And Tracking Through The...
TechSEO Boost 2021 - The Future Is The Past: Tagging And Tracking Through The...TechSEO Boost 2021 - The Future Is The Past: Tagging And Tracking Through The...
TechSEO Boost 2021 - The Future Is The Past: Tagging And Tracking Through The...
 
Performance.now() fast but not furious
Performance.now()   fast but not furiousPerformance.now()   fast but not furious
Performance.now() fast but not furious
 
Amp your site: An intro to accelerated mobile pages
Amp your site: An intro to accelerated mobile pagesAmp your site: An intro to accelerated mobile pages
Amp your site: An intro to accelerated mobile pages
 
Accelerated Mobile Pages (AMP)
Accelerated Mobile Pages (AMP)Accelerated Mobile Pages (AMP)
Accelerated Mobile Pages (AMP)
 
Prabhanjan Panigrahi
Prabhanjan PanigrahiPrabhanjan Panigrahi
Prabhanjan Panigrahi
 
Does This Theme Make My Website Look Fat? (Wordcamp SLC 2013)
Does This Theme Make My Website Look Fat? (Wordcamp SLC 2013)Does This Theme Make My Website Look Fat? (Wordcamp SLC 2013)
Does This Theme Make My Website Look Fat? (Wordcamp SLC 2013)
 
Can we make es6 the baseline of the “modern web”? - BrazilJS 2105
Can we make es6 the baseline of the “modern web”? - BrazilJS 2105 Can we make es6 the baseline of the “modern web”? - BrazilJS 2105
Can we make es6 the baseline of the “modern web”? - BrazilJS 2105
 
WordCamp Denmark Keynote
WordCamp Denmark KeynoteWordCamp Denmark Keynote
WordCamp Denmark Keynote
 
Raiders of the Fast Start: Frontend Performance Archaeology - Performance.now...
Raiders of the Fast Start: Frontend Performance Archaeology - Performance.now...Raiders of the Fast Start: Frontend Performance Archaeology - Performance.now...
Raiders of the Fast Start: Frontend Performance Archaeology - Performance.now...
 

Similaire à Performance Tuning Web Apps - The Need For Speed

The Need For Speed
The Need For SpeedThe Need For Speed
The Need For Speed
Andy Davies
 
Web Client Performance
Web Client PerformanceWeb Client Performance
Web Client Performance
Herea Adrian
 
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
Meagan Hanes
 
Csdn Drdobbs Tenni Theurer Yahoo
Csdn Drdobbs Tenni Theurer YahooCsdn Drdobbs Tenni Theurer Yahoo
Csdn Drdobbs Tenni Theurer Yahoo
guestb1b95b
 

Similaire à Performance Tuning Web Apps - The Need For Speed (20)

The 5 most common reasons for a slow WordPress site and how to fix them – ext...
The 5 most common reasons for a slow WordPress site and how to fix them – ext...The 5 most common reasons for a slow WordPress site and how to fix them – ext...
The 5 most common reasons for a slow WordPress site and how to fix them – ext...
 
Speed up Your Joomla Site for Ultimate Performance
Speed up Your Joomla Site for Ultimate PerformanceSpeed up Your Joomla Site for Ultimate Performance
Speed up Your Joomla Site for Ultimate Performance
 
Os Smarr
Os SmarrOs Smarr
Os Smarr
 
JS digest. Decemebr 2017
JS digest. Decemebr 2017JS digest. Decemebr 2017
JS digest. Decemebr 2017
 
Show Me The Cache!
Show Me The Cache!Show Me The Cache!
Show Me The Cache!
 
Ruby on Rails Performance Tuning. Make it faster, make it better (WindyCityRa...
Ruby on Rails Performance Tuning. Make it faster, make it better (WindyCityRa...Ruby on Rails Performance Tuning. Make it faster, make it better (WindyCityRa...
Ruby on Rails Performance Tuning. Make it faster, make it better (WindyCityRa...
 
Windy cityrails performance_tuning
Windy cityrails performance_tuningWindy cityrails performance_tuning
Windy cityrails performance_tuning
 
The Need For Speed
The Need For SpeedThe Need For Speed
The Need For Speed
 
The 5 most common reasons for a slow WordPress site and how to fix them
The 5 most common reasons for a slow WordPress site and how to fix themThe 5 most common reasons for a slow WordPress site and how to fix them
The 5 most common reasons for a slow WordPress site and how to fix them
 
Web Performance, Scalability, and Testing Techniques - Boston PHP Meetup
Web Performance, Scalability, and Testing Techniques - Boston PHP MeetupWeb Performance, Scalability, and Testing Techniques - Boston PHP Meetup
Web Performance, Scalability, and Testing Techniques - Boston PHP Meetup
 
Make Drupal Run Fast - increase page load speed
Make Drupal Run Fast - increase page load speedMake Drupal Run Fast - increase page load speed
Make Drupal Run Fast - increase page load speed
 
5 critical-optimizations.v2
5 critical-optimizations.v25 critical-optimizations.v2
5 critical-optimizations.v2
 
Web Client Performance
Web Client PerformanceWeb Client Performance
Web Client Performance
 
Joomla! Performance on Steroids
Joomla! Performance on SteroidsJoomla! Performance on Steroids
Joomla! Performance on Steroids
 
Universal apps lightning talk
Universal apps lightning talk Universal apps lightning talk
Universal apps lightning talk
 
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
 
Extreme Web Performance for Mobile Devices - Velocity Barcelona 2014
Extreme Web Performance for Mobile Devices - Velocity Barcelona 2014Extreme Web Performance for Mobile Devices - Velocity Barcelona 2014
Extreme Web Performance for Mobile Devices - Velocity Barcelona 2014
 
Datasets, APIs, and Web Scraping
Datasets, APIs, and Web ScrapingDatasets, APIs, and Web Scraping
Datasets, APIs, and Web Scraping
 
Csdn Drdobbs Tenni Theurer Yahoo
Csdn Drdobbs Tenni Theurer YahooCsdn Drdobbs Tenni Theurer Yahoo
Csdn Drdobbs Tenni Theurer Yahoo
 
Caching 101
Caching 101Caching 101
Caching 101
 

Plus de Vijay Rayapati

Plus de Vijay Rayapati (14)

Botmetric Product Design Process
Botmetric Product Design ProcessBotmetric Product Design Process
Botmetric Product Design Process
 
Lessons learned scaling big data in cloud
Lessons learned   scaling big data in cloudLessons learned   scaling big data in cloud
Lessons learned scaling big data in cloud
 
Scalable load testing using jmeter in cloud
Scalable load testing using jmeter in cloudScalable load testing using jmeter in cloud
Scalable load testing using jmeter in cloud
 
Big Data and Hadoop in Cloud - Leveraging Amazon EMR
Big Data and Hadoop in Cloud - Leveraging Amazon EMRBig Data and Hadoop in Cloud - Leveraging Amazon EMR
Big Data and Hadoop in Cloud - Leveraging Amazon EMR
 
Building Culture at Kuliza
Building Culture at KulizaBuilding Culture at Kuliza
Building Culture at Kuliza
 
Introduction to cloud computing - za garage talks
Introduction to cloud computing -  za garage talksIntroduction to cloud computing -  za garage talks
Introduction to cloud computing - za garage talks
 
"Introduction Open Graph and Facebook Platform" - Facebook Developer Garage ...
"Introduction Open Graph and Facebook Platform" -  Facebook Developer Garage ..."Introduction Open Graph and Facebook Platform" -  Facebook Developer Garage ...
"Introduction Open Graph and Facebook Platform" - Facebook Developer Garage ...
 
"Leveraging Virality aspects in Facebook Platform" -- Facebook Developer Gar...
"Leveraging Virality aspects in Facebook Platform" --  Facebook Developer Gar..."Leveraging Virality aspects in Facebook Platform" --  Facebook Developer Gar...
"Leveraging Virality aspects in Facebook Platform" -- Facebook Developer Gar...
 
"Smart Hiring App on Facebook" - Facebook Developer Garage Bangalore
"Smart Hiring App on Facebook"  -  Facebook Developer Garage Bangalore"Smart Hiring App on Facebook"  -  Facebook Developer Garage Bangalore
"Smart Hiring App on Facebook" - Facebook Developer Garage Bangalore
 
"Facebook Platform Best Practices" - Facebook Developer Garage Bangalore
"Facebook Platform Best Practices" -  Facebook Developer Garage Bangalore"Facebook Platform Best Practices" -  Facebook Developer Garage Bangalore
"Facebook Platform Best Practices" - Facebook Developer Garage Bangalore
 
How Cafe Coffee Day Handled Their Online Crisis
How Cafe Coffee Day Handled Their Online CrisisHow Cafe Coffee Day Handled Their Online Crisis
How Cafe Coffee Day Handled Their Online Crisis
 
Giza Page Hiring
Giza Page HiringGiza Page Hiring
Giza Page Hiring
 
Nasscom Product Conclave 2009 - Feedback collected using Twitter
Nasscom Product Conclave 2009 - Feedback collected using TwitterNasscom Product Conclave 2009 - Feedback collected using Twitter
Nasscom Product Conclave 2009 - Feedback collected using Twitter
 
Social Media Engagement
Social Media EngagementSocial Media Engagement
Social Media Engagement
 

Dernier

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
 
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Victor Rentea
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
WSO2
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Victor Rentea
 

Dernier (20)

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...
 
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
 
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
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
 
CNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In PakistanCNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In Pakistan
 
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
 
[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 
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
 
Exploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with MilvusExploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with Milvus
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Platformless Horizons for Digital Adaptability
Platformless Horizons for Digital AdaptabilityPlatformless Horizons for Digital Adaptability
Platformless Horizons for Digital Adaptability
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
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
 
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot ModelMcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
 

Performance Tuning Web Apps - The Need For Speed

  • 1. The NEED FOR SPEED on WEB! Vijay Rayapati Product@GizaPage @amnigos
  • 2. Note : Do follow barcamp Rules!
  • 3.
  • 4. Performance Tuning Your Web Apps Why SPEED matters?
  • 5. The most impatient creature on the earth 
  • 7. RecentlyFred Wilson spoke about And the first GOLDEN rule is SPEED
  • 8. If VC’s are talking about WEB apps SPEED that means the problem is mainstream
  • 9. What SPEED means for WEB? Facebook created PHP HipHop to speedup=F****ing 50% savings! Web would have been a great place if everything worked like a Google Instant Lot’s of bad PR and Loose users! Tip : Do join us at Facebook Developer Garage Bangalore on 24th, September for indepth discussion on HipHop.
  • 10. But Why You Should Worry? because It is about User Experience and Engagement Slow = High Bounce Rates = No users Average users are mostly likely to quit a slow page than geeks It affects your SEO – think Google Instant but IRCTC still works in India 
  • 11. AND… Only DOGS can sleep while pages are loading 
  • 12. AND… When was the last time you were waiting for the page to load without cursing it?
  • 13. What’s a Good Page Speed? F**K this Page 10 seconds SPEEED is not a feature, it’s a KILLER! 5 seconds 2.5 seconds Google loads in 823 milliseconds* * : Yotta report
  • 14. God once said SPEED first EVERYTHING next * : Whom should I quote here? 
  • 15. Lot’s of sites suck on the WEB!
  • 16. And it’s sick to use so many lousy pages
  • 17. Hey Talk is cheap…Show me the code…
  • 18. Murphy's Law is usually more applicable than Moore's Law Premature optimization is the root cause of all evils - Knuth
  • 19. What Should I Do to SPEED UP? Lets optimize JAVA/.NET/PHP CODE = FUCK it I think APACHE is better than IIS = FUCK it Lets get Intel XYZ7 processor = FUCK it Lets move to Cloud = FUCK It
  • 20. The 80-20 Rule Let’s not worry much Problem is HERE To Speed Up To Scale Up
  • 21. What Browsers do? Note : From big brother MS IE Blog!
  • 22. The Birth and Death of a Page Note : Thanks to Steven Stefanov for this beauty
  • 23. Note : From big brother MS IE Blog!
  • 24. And the browser woes… Number of connections per host = every browser does it’s own way! Maximum numberof connections from browser. JavaScriptengines suck! So many cool effects – I need more JAVASCRIPT HTTP was built in B.C and we need SPEEDY! Enough SHIT lets get to the POINT >>
  • 25. Good news – lot’s of tools Page Speed Speed Tracer Y slow Firebug Webpage SpeedTest Dynatrace Ajax and many more are there!
  • 26. The Golden Rules 1. Do LESS : Reduce HTTP requests – combine JS files, CSS files, Use Image Sprites 2. Do SMALL : Smush.it/PNG Crush Images, Minify JS/CSS, Remove fugly code 3. Do COOL : Cache JS/CSS/Images, Google “optimize” options for your server  4. Do MORE : Parallel connections, Order your stuff, Unblock JS & Use Google ajax libs 5. Do GEEKY : XHR use JSON, Flush() early, Gzip, Dump Etags, Cache on Server & CDN 6. Do SMART: Lazy load, Upgrade your JS libs, Cleanup JS files & Get of rid of comments/code – the EVIL Tell me other 4 rules 
  • 27. Thumb Rulesfor 90% Use Google Closure Compiler – easiest way to optimize your JS. Play with Cuzillionto learn how to order Images, inline/external Javascripts/CSS Upgrade your jQuery/others libs regularly – faster and less memory Do basic optimization of your JS code, just google – ton of resources
  • 28. Thumb Rulesfor 90% Don’t put JS libraries on your server unless required – Use Google or MS public CDN’s Burst the Cache on updates – use ? or include versioning in build script Use SpritesMeand learn image sprites – saves you a ton of load. Lazy load/Pre-fetch if have too much stuff after page load or anticipate next page – XHR, JSON : Love jQuery
  • 29. If you have just wordpress Try one of those cache plug-ins like w3-total-cache
  • 30. Why you should focus on ordering your stuff?
  • 31. Increase Parallel Downloads Note : Too many hosts will end up with DNS look up overhead
  • 32. How to do Async JS loading? RequireJS– Awesome way to load JS async and also handle dependencies
  • 33. How to Measure Ajax actions? Dynatrace Ajax – If John Resig is impressed then you should also be 
  • 34. How to Measure Ajax actions? Chrome Speed Tracer – This is a kick-ass 
  • 35. How to Measure Ajax actions? Chrome Speed Tracer – This is a kick-ass 
  • 36. Geeky: How to do JS payload split? Why load all the JS code upfront when you only need some of it? Doloto - http://msdn.microsoft.com/en-us/devlabs/ee423534.aspx
  • 37. Word of caution A/B and Multivariate scripts will have impact on performance Choose user screen captures tools carefully – can get really sluggish Get rid of asp.net ajax libs, bloated and lousy! Choose your social or JS framework plug-ins carefully – most are lousy! and Look at your server logs – gives you ton of data on requests/responses Do backend profiling – if you have high loads on the system
  • 38. When NOT to optimize?
  • 39. The Future looks brighter! Web workers – run multiple JS threads! Hardware acceleration in Browsers – faster rendering/scaling/layouts The awesome HTML 5 – Async/Defer, local storage/app cache, Web SQL & more! Expect better JS engines – run highly optimized and native vm code May be SPEEDY/Web Resource Bundles Soon!
  • 40. Hope All Browsers will have auto update, love you Chrome! Can we do something for IE 6? – the death funerals haven’t worked yet 
  • 41. Follow Leaders The Yahoo Developer Network Performance Section Google Performance Engineering Site Steve Souders((@souders) Facebook Engineering Blog Performance Planet John Resig High Scalability InfoQ Nicole Sullivan(@stubbornella) Phillip Tellis((@bluesmoon))
  • 42. Let’s make WEB faster! May god bless the speed Vijay Rayapati Product@GizaPage @amnigos
  • 43. Few last things Thanks to friends at #BCB9 Sponsorship!
  • 44. Credits It’s due wherever I used images from Flickr CC, FindIcons.com and Google Images Search  Thanks to Pallav (FusionCharts ) for the background theme.