SlideShare a Scribd company logo
A long time ago…
dovchar 2014
✦ 8 years in IT
✦ 4 years in SoftServe
✦ 1.5 years Application Architect
✦ Main language: Javascript
✦ Hobby language: Go
✦ Pacemaker conference
✦ Script’n’Code meet-up
✦ Open source (typescript grails, clio
go, sonar qunit, kojak, jspro)
dovcharlvivjs2014
Aboutme
dovcharlvivks2014
Agenda
✦ About Project
✦ Memory leaks, how are you
✦ Why some actions so slow?!
✦ Start analyzing
✦ JS tools
✦ Chrome, iOS monitoring, Kojak, jsPro,
PSI, Chrome remote debug
✦ Examples
✦ Questions?..
ProjectStatistic
✦ 3 years development
✦ 10 scrum teams
✦ 59 modules
✦ 3200 javascript files
✦ 200.000 lines of code
✦ 1.226 total violations
✦ 70.3% code coverage
✦ 83.0% code health
dovcharlvivjs2014
AboutProjectdovcharlvivjs2014
iPad2 is falling down
dovcharlvivjs2014
Dima WTF…, Why some actions are so SLOW?!
dovcharlvivjs2014
dovcharlvivjs2014
StartAnalysing
✦ Include analytic tools: google analytics, New Relic,
AppDynamics, etc
✦ BAs should prepare top 10-15 pages most used
✦ BAs + QC should prepare test workflows for those pages
✦ Prepare data for tests, infrastructure (load balancer, cdn,
servers, db) very close to production
✦ Prepare test tools for testing and come to an agreement
with the stakeholders (because they might be commercial,
not free)
✦ Preliminary data gathering from one or two scenarios
✦ Need to teach your team how to work with tool set and
manage its data
✦ Automate as much as you can
dovcharlvivjs2014
Tools
✦ Chrome dev tools
✦ Chrome remote debugger
✦ Xcode iOS monitoring
✦ AppDynamics UX plugin
✦ Google analytics
✦ Kojak
✦ KojakSync + jsPro
✦ PageSpead Insights (PSI API)
dovcharlvivjs2014
GoogleAnalyticsdovcharlvivjs2014
GoogleAnalytics
✦ Google Analytics is built on a powerful, easy-to-use reporting
platform, so that you can decide what data you want to view
and customize your reports, with just a few clicks
✦ Content reports help you understand which parts of your
website are performing well and which pages are most
popular so that you can create a better experience for your
customers
✦ You can analyse how visitors interact with sharing features on
your site (like the Google +1 button) and engage with your
content across social platforms
✦ Google Analytics helps you measure the impact of mobile on
your business
✦ Find out how many customers you're attracting, how much
you're selling and how users are engaging with your site with
Google Analytics' range of analysis features.
✦ Make the most of your advertising by learning how well your
social, mobile, search and display ads are working
dovcharlvivjs2014
Xcodedovcharlvivjs2014
Xcodedovcharlvivjs2014
Xcodedovcharlvivjs2014
Xcodedovcharlvivjs2014
ChromeToolsdovcharlvivjs2014
html5rocks.com
Memorymodedovcharlvivjs2014
Chrome Dev Tools -> Timeline
Memorysnapshotdovcharlvivjs2014
CD Tools -> Profiles -> Take Heap Snapshot
TaskManager
Menu -> Tools -> Task Manager
dovcharlvivjs2014
ChromeRDdovcharlvivjs2014
ios-webkit-debug-proxy
AppDynamicsUXdovcharlvivjs2014
✦ Where your heaviest loads originate
✦ Where your slowest end-user response times occur
✦ how performance varies by location
✦ how performance varies by client type, device, browser and
browser version,network connection
✦ how performance varies by application and application version,
operating system version, device, carrier for mobile apps
✦ what your slowest Web requests/Ajax requests are and what is
causing the slowdown
✦ what your slowest mobile network requests are and what is
causing the slowdown
✦ how application server performance impacts the performance of
your web and mobile traffic
AppDynamicsUXdovcharlvivjs2014
Kojakdovcharlvivjs2014
WhoisKojak
«Kojak is an American television series starring Telly Savalas as the title
character, New York City Police Department Detective Lieutenant Theo Kojak.
Taking the time slot of the popular Cannon series, moved one hour earlier, it aired
on CBS from October 24, 1973, to March 18, 1978. In 1999 TV Guide ranked Theo
Kojak number 18 on its 50 Greatest TV Characters of All Time list»
Wikipedia
dovcharlvivjs2014
KojakJS
Kojak is a simple utility that can help you figure out which of your
JavaScript functions are running too slow. It tracks when your
functions are called, how often they are called, how much time
they are taking, how the functions were called. It can also track
your ajax calls and help figure out how fast they are.
What is Kojak JS?
dovcharlvivjs2014
Features
✦ Kojak helps you focus on the performance of your own code
and eliminate the clutter
✦ Kojak is a tool that would remove all of the noise and clutter
✦ Kojak is a tool that was easy to configure and didn't force you to
inject hooks all over my code
✦ The core of Kojak has no external dependencies
✦ We can easily integrate Kojak with Backbone, Angular or
Ember
✦ Measure isolated time of your functions. IsolatedTime is how
much cumulative time was spent inside the function itself
✦ Measure functions call count. Call count how often some
functions has called.
✦ Tracking performance in between actions
✦ Tracking Network Requests
dovcharlvivjs2014
Explanation
Aspect-Oriented Programming
(AOP) is a programming paradigm
that aims to increase modularity by
allowing the separation of cross-
cutting concerns. AOP forms a basis
for aspect-oriented software
development.
dovcharlvivjs2014
HowTo
✦ To use Kojak copy/download the Kojak.min.js file from
github.com/theironcook/Kojak. Include it in the browser code you
want to profile.
✦ Kojak needs to be told what code it is supposed to profile. You tell
Kojak via the command: kConfig.setIncludedPakages(['packageA',
‘packageB’]);
✦ After you've told Kojak what it should are about and what to exclude
you need to run this command: kInst.instrument();
✦ Start tracking performance in between actions: run
kInst.takeCheckpoint(); for creating checkpoint before actions begin.
✦ After doing some use cases run kRep.funcPerfAfterCheckpoint(); and
collect isolated time and call count all functions has ran from last
kInst.takeCheckpoint();
✦ Kojak can also track all of your network ajax requests. To use the
NetWatcher you must use jQuery. To enable run this command:
kConfig.setEnableNetWatcher(true); and kRep.netCalls(); after
dovcharlvivjs2014
Consoleexampledovcharlvivjs2014
IsolatedTime
Program
funcA()
funcB()
funcC()
funcA()
5ms
funcB()
10ms
funcC()
15ms
dovcharlvivjs2014
IsolatedTime
Program
funcA()
funcA()
5ms
funcB()
10ms
funcC()
15ms
1 5
dovcharlvivjs2014
IsolatedTime
Program
funcA()
funcA()
5ms
funcB()
10ms
funcC()
15ms
325
1 5 jFunc()
50ms
1
dovcharlvivjs2014
IsolatedTime
Program
funcA()
funcA()
5ms
funcB()
10ms
funcC()
15ms
15
1 5 async()
50ms
1
dovcharlvivjs2014
jsProdovcharlvivjs2014
jsPro
Kojak&jsPro
KojakSync#1 KojakSync#2 KojakSync#N
jsPro Visualization
Storage
dovcharlvivjs2014
Kojak&jsProdovcharlvivjs2014
Kojak&jsPro
✦ To use KojakSync copy/download the Kojak.js file from
github.com/dovchar/KojakSync. Include it in the browser code
you want to profile
✦ Go to jspro.herokuapp.com
✦ Login with your github account -> your name -> my apps ->
click «create new» button -> copy API Key and Secret Key
✦ Run Google Chrome with flags:
—enable-memory-info --js-flags="--expose-gc"
✦ Enable kojak sync functionality: kConfig.sync('secretKey',
‘apiKey');
✦ Todo all steps like with native Kojak for collect data
dovcharlvivjs2014
Kojak&jsPro
Demo…
dovcharlvivjs2014
NextSteps
✦ Prepare good documentation
✦ Stabilize jsPro application (fix bugs)
✦ Extend functionality
✦ Integrate Google PSI API
✦ Integrate Chrome Remote Debugger
✦ Collect errors from UI
✦ Snapshots by User session for
production usage
✦ Granular collecting data for prod
mode
dovcharlvivjs2014
Conclusiondovcharlvivjs2014
Links
✦ AppDynamics
✦ Google Analytics
✦ Chrome Dev Tools
✦ Kojak, KojakSync, jsPro
✦ pacemaker, script’n’code
✦ Sails.js
Facebook Twitter Linkedin Gmail
dovcharlvivjs2014
Questionsdovcharlvivjs2014

More Related Content

What's hot

Bgoug 2019.11 test your pl sql - not your patience
Bgoug 2019.11   test your pl sql - not your patienceBgoug 2019.11   test your pl sql - not your patience
Bgoug 2019.11 test your pl sql - not your patience
Jacek Gebal
 
Gradle : An introduction
Gradle : An introduction Gradle : An introduction
Gradle : An introduction
Nibodha Technologies
 
Automating Deployments with Deployer - php[world] 2018
Automating Deployments with Deployer - php[world] 2018Automating Deployments with Deployer - php[world] 2018
Automating Deployments with Deployer - php[world] 2018
Colin O'Dell
 
An Introduction to Gradle for Java Developers
An Introduction to Gradle for Java DevelopersAn Introduction to Gradle for Java Developers
An Introduction to Gradle for Java Developers
Kostas Saidis
 
Ratpack 101 - GR8Conf 2015
Ratpack 101 - GR8Conf 2015Ratpack 101 - GR8Conf 2015
Ratpack 101 - GR8Conf 2015
Alvaro Sanchez-Mariscal
 
Continuous delivery w projekcie open source - Marcin Stachniuk
Continuous delivery w projekcie open source - Marcin StachniukContinuous delivery w projekcie open source - Marcin Stachniuk
Continuous delivery w projekcie open source - Marcin Stachniuk
MarcinStachniuk
 
Forget Grunt and Gulp! Webpack and NPM rule them all!
Forget Grunt and Gulp! Webpack and NPM rule them all!Forget Grunt and Gulp! Webpack and NPM rule them all!
Forget Grunt and Gulp! Webpack and NPM rule them all!
Derek Willian Stavis
 
Grunt & Front-end Workflow
Grunt & Front-end WorkflowGrunt & Front-end Workflow
Grunt & Front-end Workflow
Pagepro
 
Git-deliver Ignite slides for DevOps Days Paris 2015
Git-deliver Ignite slides for DevOps Days Paris 2015Git-deliver Ignite slides for DevOps Days Paris 2015
Git-deliver Ignite slides for DevOps Days Paris 2015
Arnaud_Betremieux
 
Microservices in Golang
Microservices in GolangMicroservices in Golang
Microservices in Golang
Mo'ath Qasim
 
Gradle
GradleGradle
Gradle presentation
Gradle presentationGradle presentation
Gradle presentation
Oriol Jiménez
 
SKS in git ops mode
SKS in git ops modeSKS in git ops mode
SKS in git ops mode
Raphaël PINSON
 
Gradle build automation tool
Gradle   build automation toolGradle   build automation tool
Gradle build automation tool
Ioan Eugen Stan
 
Continuous Delivery w projekcie Open Source - Marcin Stachniuk - DevCrowd 2017
Continuous Delivery w projekcie Open Source - Marcin Stachniuk - DevCrowd 2017Continuous Delivery w projekcie Open Source - Marcin Stachniuk - DevCrowd 2017
Continuous Delivery w projekcie Open Source - Marcin Stachniuk - DevCrowd 2017
MarcinStachniuk
 
Deploying Plack Web Applications: OSCON 2011
Deploying Plack Web Applications: OSCON 2011Deploying Plack Web Applications: OSCON 2011
Deploying Plack Web Applications: OSCON 2011
Tatsuhiko Miyagawa
 
11 Tools for your Open Source devops stack
11 Tools for your Open Source devops stack 11 Tools for your Open Source devops stack
11 Tools for your Open Source devops stack
Kris Buytaert
 
wp-cli and plugin development with future and past compatibility (Word Camp P...
wp-cli and plugin development with future and past compatibility (Word Camp P...wp-cli and plugin development with future and past compatibility (Word Camp P...
wp-cli and plugin development with future and past compatibility (Word Camp P...
Andreas - Creten
 
Pipeline all the Dashboards as Code
Pipeline all the Dashboards as CodePipeline all the Dashboards as Code
Pipeline all the Dashboards as Code
Kris Buytaert
 
Gradle - time for a new build
Gradle - time for a new buildGradle - time for a new build
Gradle - time for a new build
Igor Khotin
 

What's hot (20)

Bgoug 2019.11 test your pl sql - not your patience
Bgoug 2019.11   test your pl sql - not your patienceBgoug 2019.11   test your pl sql - not your patience
Bgoug 2019.11 test your pl sql - not your patience
 
Gradle : An introduction
Gradle : An introduction Gradle : An introduction
Gradle : An introduction
 
Automating Deployments with Deployer - php[world] 2018
Automating Deployments with Deployer - php[world] 2018Automating Deployments with Deployer - php[world] 2018
Automating Deployments with Deployer - php[world] 2018
 
An Introduction to Gradle for Java Developers
An Introduction to Gradle for Java DevelopersAn Introduction to Gradle for Java Developers
An Introduction to Gradle for Java Developers
 
Ratpack 101 - GR8Conf 2015
Ratpack 101 - GR8Conf 2015Ratpack 101 - GR8Conf 2015
Ratpack 101 - GR8Conf 2015
 
Continuous delivery w projekcie open source - Marcin Stachniuk
Continuous delivery w projekcie open source - Marcin StachniukContinuous delivery w projekcie open source - Marcin Stachniuk
Continuous delivery w projekcie open source - Marcin Stachniuk
 
Forget Grunt and Gulp! Webpack and NPM rule them all!
Forget Grunt and Gulp! Webpack and NPM rule them all!Forget Grunt and Gulp! Webpack and NPM rule them all!
Forget Grunt and Gulp! Webpack and NPM rule them all!
 
Grunt & Front-end Workflow
Grunt & Front-end WorkflowGrunt & Front-end Workflow
Grunt & Front-end Workflow
 
Git-deliver Ignite slides for DevOps Days Paris 2015
Git-deliver Ignite slides for DevOps Days Paris 2015Git-deliver Ignite slides for DevOps Days Paris 2015
Git-deliver Ignite slides for DevOps Days Paris 2015
 
Microservices in Golang
Microservices in GolangMicroservices in Golang
Microservices in Golang
 
Gradle
GradleGradle
Gradle
 
Gradle presentation
Gradle presentationGradle presentation
Gradle presentation
 
SKS in git ops mode
SKS in git ops modeSKS in git ops mode
SKS in git ops mode
 
Gradle build automation tool
Gradle   build automation toolGradle   build automation tool
Gradle build automation tool
 
Continuous Delivery w projekcie Open Source - Marcin Stachniuk - DevCrowd 2017
Continuous Delivery w projekcie Open Source - Marcin Stachniuk - DevCrowd 2017Continuous Delivery w projekcie Open Source - Marcin Stachniuk - DevCrowd 2017
Continuous Delivery w projekcie Open Source - Marcin Stachniuk - DevCrowd 2017
 
Deploying Plack Web Applications: OSCON 2011
Deploying Plack Web Applications: OSCON 2011Deploying Plack Web Applications: OSCON 2011
Deploying Plack Web Applications: OSCON 2011
 
11 Tools for your Open Source devops stack
11 Tools for your Open Source devops stack 11 Tools for your Open Source devops stack
11 Tools for your Open Source devops stack
 
wp-cli and plugin development with future and past compatibility (Word Camp P...
wp-cli and plugin development with future and past compatibility (Word Camp P...wp-cli and plugin development with future and past compatibility (Word Camp P...
wp-cli and plugin development with future and past compatibility (Word Camp P...
 
Pipeline all the Dashboards as Code
Pipeline all the Dashboards as CodePipeline all the Dashboards as Code
Pipeline all the Dashboards as Code
 
Gradle - time for a new build
Gradle - time for a new buildGradle - time for a new build
Gradle - time for a new build
 

Viewers also liked

Utilizing Traditional and Social Media
Utilizing Traditional and Social MediaUtilizing Traditional and Social Media
Utilizing Traditional and Social Media
Brooke Hardison
 
Tata photon outbound process
Tata photon outbound processTata photon outbound process
Tata photon outbound process
ritesh008
 
Reliance order taking process
Reliance order taking processReliance order taking process
Reliance order taking process
ritesh008
 
Rediffdeal customer care without upfront
Rediffdeal customer care   without upfrontRediffdeal customer care   without upfront
Rediffdeal customer care without upfront
ritesh008
 
E bay inbound process
E bay inbound processE bay inbound process
E bay inbound process
ritesh008
 
Mts form filling project
Mts form filling projectMts form filling project
Mts form filling project
ritesh008
 
Pharma inbound voice process without upfront
Pharma inbound voice process   without upfrontPharma inbound voice process   without upfront
Pharma inbound voice process without upfront
ritesh008
 
Hdfc form filling process
Hdfc form filling processHdfc form filling process
Hdfc form filling process
ritesh008
 
Lic form filling process online
Lic form filling process   onlineLic form filling process   online
Lic form filling process online
ritesh008
 
Docomo
DocomoDocomo
Snap deal order verification process
Snap deal order verification processSnap deal order verification process
Snap deal order verification process
ritesh008
 
BPO NON-VOICE CHEMICAL FORM FILLING PROJECTS
BPO NON-VOICE CHEMICAL FORM FILLING PROJECTSBPO NON-VOICE CHEMICAL FORM FILLING PROJECTS
BPO NON-VOICE CHEMICAL FORM FILLING PROJECTS
BPOFORMFILLINGPROJECTS
 
BPO Non-Voice Mobile Form Filing Projects
BPO Non-Voice Mobile Form Filing ProjectsBPO Non-Voice Mobile Form Filing Projects
BPO Non-Voice Mobile Form Filing Projects
BPOFORMFILLINGPROJECTS
 
Icici project
Icici projectIcici project
Icici project
Neeraj Parihar
 
Resume
ResumeResume
Resume
narsglance
 
Net Promoter Score Pitfalls to Avoid
Net Promoter Score Pitfalls to AvoidNet Promoter Score Pitfalls to Avoid
Net Promoter Score Pitfalls to Avoid
Aureus Analytics
 
Habits at Work - Merci Victoria Grace, Growth, Slack - 2016 Habit Summit
Habits at Work - Merci Victoria Grace, Growth, Slack - 2016 Habit SummitHabits at Work - Merci Victoria Grace, Growth, Slack - 2016 Habit Summit
Habits at Work - Merci Victoria Grace, Growth, Slack - 2016 Habit Summit
Habit Summit
 

Viewers also liked (17)

Utilizing Traditional and Social Media
Utilizing Traditional and Social MediaUtilizing Traditional and Social Media
Utilizing Traditional and Social Media
 
Tata photon outbound process
Tata photon outbound processTata photon outbound process
Tata photon outbound process
 
Reliance order taking process
Reliance order taking processReliance order taking process
Reliance order taking process
 
Rediffdeal customer care without upfront
Rediffdeal customer care   without upfrontRediffdeal customer care   without upfront
Rediffdeal customer care without upfront
 
E bay inbound process
E bay inbound processE bay inbound process
E bay inbound process
 
Mts form filling project
Mts form filling projectMts form filling project
Mts form filling project
 
Pharma inbound voice process without upfront
Pharma inbound voice process   without upfrontPharma inbound voice process   without upfront
Pharma inbound voice process without upfront
 
Hdfc form filling process
Hdfc form filling processHdfc form filling process
Hdfc form filling process
 
Lic form filling process online
Lic form filling process   onlineLic form filling process   online
Lic form filling process online
 
Docomo
DocomoDocomo
Docomo
 
Snap deal order verification process
Snap deal order verification processSnap deal order verification process
Snap deal order verification process
 
BPO NON-VOICE CHEMICAL FORM FILLING PROJECTS
BPO NON-VOICE CHEMICAL FORM FILLING PROJECTSBPO NON-VOICE CHEMICAL FORM FILLING PROJECTS
BPO NON-VOICE CHEMICAL FORM FILLING PROJECTS
 
BPO Non-Voice Mobile Form Filing Projects
BPO Non-Voice Mobile Form Filing ProjectsBPO Non-Voice Mobile Form Filing Projects
BPO Non-Voice Mobile Form Filing Projects
 
Icici project
Icici projectIcici project
Icici project
 
Resume
ResumeResume
Resume
 
Net Promoter Score Pitfalls to Avoid
Net Promoter Score Pitfalls to AvoidNet Promoter Score Pitfalls to Avoid
Net Promoter Score Pitfalls to Avoid
 
Habits at Work - Merci Victoria Grace, Growth, Slack - 2016 Habit Summit
Habits at Work - Merci Victoria Grace, Growth, Slack - 2016 Habit SummitHabits at Work - Merci Victoria Grace, Growth, Slack - 2016 Habit Summit
Habits at Work - Merci Victoria Grace, Growth, Slack - 2016 Habit Summit
 

Similar to JS performance tools

Intro To Django
Intro To DjangoIntro To Django
Intro To Django
Udi Bauman
 
So you want to build a mobile app - HTML5 vs. Native @ the Boston Mobile Expe...
So you want to build a mobile app - HTML5 vs. Native @ the Boston Mobile Expe...So you want to build a mobile app - HTML5 vs. Native @ the Boston Mobile Expe...
So you want to build a mobile app - HTML5 vs. Native @ the Boston Mobile Expe...
Yottaa
 
GDD Japan 2009 - Designing OpenSocial Apps For Speed and Scale
GDD Japan 2009 - Designing OpenSocial Apps For Speed and ScaleGDD Japan 2009 - Designing OpenSocial Apps For Speed and Scale
GDD Japan 2009 - Designing OpenSocial Apps For Speed and Scale
Patrick Chanezon
 
Move out from AppEngine, and Python PaaS alternatives
Move out from AppEngine, and Python PaaS alternativesMove out from AppEngine, and Python PaaS alternatives
Move out from AppEngine, and Python PaaS alternatives
tzang ms
 
Deep crawl the chaotic landscape of JavaScript
Deep crawl the chaotic landscape of JavaScript Deep crawl the chaotic landscape of JavaScript
Deep crawl the chaotic landscape of JavaScript
Onely
 
Measure camp tools of the cro rabble
Measure camp   tools of the cro rabbleMeasure camp   tools of the cro rabble
Measure camp tools of the cro rabble
Craig Sullivan
 
State of jQuery '09
State of jQuery '09State of jQuery '09
State of jQuery '09
jeresig
 
Aws uk ug #8 not everything that happens in vegas stay in vegas
Aws uk ug #8   not everything that happens in vegas stay in vegasAws uk ug #8   not everything that happens in vegas stay in vegas
Aws uk ug #8 not everything that happens in vegas stay in vegas
Peter Mounce
 
Continuous integration at CartoDB
Continuous integration at CartoDBContinuous integration at CartoDB
Continuous integration at CartoDB
Juan Ignacio Sánchez Lara
 
20101017 program analysis_for_security_livshits_lecture04_nozzle
20101017 program analysis_for_security_livshits_lecture04_nozzle20101017 program analysis_for_security_livshits_lecture04_nozzle
20101017 program analysis_for_security_livshits_lecture04_nozzle
Computer Science Club
 
Entender React Native
Entender React NativeEntender React Native
Entender React Native
Santex Group
 
Kostiantyn Yelisavenko "Mastering Macro Benchmarking in .NET"
Kostiantyn Yelisavenko "Mastering Macro Benchmarking in .NET"Kostiantyn Yelisavenko "Mastering Macro Benchmarking in .NET"
Kostiantyn Yelisavenko "Mastering Macro Benchmarking in .NET"
LogeekNightUkraine
 
JavaScript Library Overview
JavaScript Library OverviewJavaScript Library Overview
JavaScript Library Overview
jeresig
 
Gwt create2013 Frankfurt: How we built a million dollar business with GWT
Gwt create2013 Frankfurt: How we built a million dollar business with GWTGwt create2013 Frankfurt: How we built a million dollar business with GWT
Gwt create2013 Frankfurt: How we built a million dollar business with GWT
infoqafe
 
External JavaScript Widget Development Best Practices (updated) (v.1.1)
External JavaScript Widget Development Best Practices (updated) (v.1.1) External JavaScript Widget Development Best Practices (updated) (v.1.1)
External JavaScript Widget Development Best Practices (updated) (v.1.1)
Volkan Özçelik
 
Turn On The Lights
Turn On The LightsTurn On The Lights
Turn On The Lights
Postman
 
Creating a Responsive Website From Scratch
Creating a Responsive Website From ScratchCreating a Responsive Website From Scratch
Creating a Responsive Website From Scratch
Corky Brown
 
External JavaScript Widget Development Best Practices
External JavaScript Widget Development Best PracticesExternal JavaScript Widget Development Best Practices
External JavaScript Widget Development Best Practices
Volkan Özçelik
 
User first! 前端的最後一塊拼圖
User first! 前端的最後一塊拼圖User first! 前端的最後一塊拼圖
User first! 前端的最後一塊拼圖
Maxis Kao
 
Java scriptwidgetdevelopmentjstanbul2012
Java scriptwidgetdevelopmentjstanbul2012Java scriptwidgetdevelopmentjstanbul2012
Java scriptwidgetdevelopmentjstanbul2012
Volkan Özçelik
 

Similar to JS performance tools (20)

Intro To Django
Intro To DjangoIntro To Django
Intro To Django
 
So you want to build a mobile app - HTML5 vs. Native @ the Boston Mobile Expe...
So you want to build a mobile app - HTML5 vs. Native @ the Boston Mobile Expe...So you want to build a mobile app - HTML5 vs. Native @ the Boston Mobile Expe...
So you want to build a mobile app - HTML5 vs. Native @ the Boston Mobile Expe...
 
GDD Japan 2009 - Designing OpenSocial Apps For Speed and Scale
GDD Japan 2009 - Designing OpenSocial Apps For Speed and ScaleGDD Japan 2009 - Designing OpenSocial Apps For Speed and Scale
GDD Japan 2009 - Designing OpenSocial Apps For Speed and Scale
 
Move out from AppEngine, and Python PaaS alternatives
Move out from AppEngine, and Python PaaS alternativesMove out from AppEngine, and Python PaaS alternatives
Move out from AppEngine, and Python PaaS alternatives
 
Deep crawl the chaotic landscape of JavaScript
Deep crawl the chaotic landscape of JavaScript Deep crawl the chaotic landscape of JavaScript
Deep crawl the chaotic landscape of JavaScript
 
Measure camp tools of the cro rabble
Measure camp   tools of the cro rabbleMeasure camp   tools of the cro rabble
Measure camp tools of the cro rabble
 
State of jQuery '09
State of jQuery '09State of jQuery '09
State of jQuery '09
 
Aws uk ug #8 not everything that happens in vegas stay in vegas
Aws uk ug #8   not everything that happens in vegas stay in vegasAws uk ug #8   not everything that happens in vegas stay in vegas
Aws uk ug #8 not everything that happens in vegas stay in vegas
 
Continuous integration at CartoDB
Continuous integration at CartoDBContinuous integration at CartoDB
Continuous integration at CartoDB
 
20101017 program analysis_for_security_livshits_lecture04_nozzle
20101017 program analysis_for_security_livshits_lecture04_nozzle20101017 program analysis_for_security_livshits_lecture04_nozzle
20101017 program analysis_for_security_livshits_lecture04_nozzle
 
Entender React Native
Entender React NativeEntender React Native
Entender React Native
 
Kostiantyn Yelisavenko "Mastering Macro Benchmarking in .NET"
Kostiantyn Yelisavenko "Mastering Macro Benchmarking in .NET"Kostiantyn Yelisavenko "Mastering Macro Benchmarking in .NET"
Kostiantyn Yelisavenko "Mastering Macro Benchmarking in .NET"
 
JavaScript Library Overview
JavaScript Library OverviewJavaScript Library Overview
JavaScript Library Overview
 
Gwt create2013 Frankfurt: How we built a million dollar business with GWT
Gwt create2013 Frankfurt: How we built a million dollar business with GWTGwt create2013 Frankfurt: How we built a million dollar business with GWT
Gwt create2013 Frankfurt: How we built a million dollar business with GWT
 
External JavaScript Widget Development Best Practices (updated) (v.1.1)
External JavaScript Widget Development Best Practices (updated) (v.1.1) External JavaScript Widget Development Best Practices (updated) (v.1.1)
External JavaScript Widget Development Best Practices (updated) (v.1.1)
 
Turn On The Lights
Turn On The LightsTurn On The Lights
Turn On The Lights
 
Creating a Responsive Website From Scratch
Creating a Responsive Website From ScratchCreating a Responsive Website From Scratch
Creating a Responsive Website From Scratch
 
External JavaScript Widget Development Best Practices
External JavaScript Widget Development Best PracticesExternal JavaScript Widget Development Best Practices
External JavaScript Widget Development Best Practices
 
User first! 前端的最後一塊拼圖
User first! 前端的最後一塊拼圖User first! 前端的最後一塊拼圖
User first! 前端的最後一塊拼圖
 
Java scriptwidgetdevelopmentjstanbul2012
Java scriptwidgetdevelopmentjstanbul2012Java scriptwidgetdevelopmentjstanbul2012
Java scriptwidgetdevelopmentjstanbul2012
 

Recently uploaded

AI 101: An Introduction to the Basics and Impact of Artificial Intelligence
AI 101: An Introduction to the Basics and Impact of Artificial IntelligenceAI 101: An Introduction to the Basics and Impact of Artificial Intelligence
AI 101: An Introduction to the Basics and Impact of Artificial Intelligence
IndexBug
 
TrustArc Webinar - 2024 Global Privacy Survey
TrustArc Webinar - 2024 Global Privacy SurveyTrustArc Webinar - 2024 Global Privacy Survey
TrustArc Webinar - 2024 Global Privacy Survey
TrustArc
 
GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...
GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...
GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...
Neo4j
 
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
Neo4j
 
Removing Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software FuzzingRemoving Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software Fuzzing
Aftab Hussain
 
Serial Arm Control in Real Time Presentation
Serial Arm Control in Real Time PresentationSerial Arm Control in Real Time Presentation
Serial Arm Control in Real Time Presentation
tolgahangng
 
Cosa hanno in comune un mattoncino Lego e la backdoor XZ?
Cosa hanno in comune un mattoncino Lego e la backdoor XZ?Cosa hanno in comune un mattoncino Lego e la backdoor XZ?
Cosa hanno in comune un mattoncino Lego e la backdoor XZ?
Speck&Tech
 
“Building and Scaling AI Applications with the Nx AI Manager,” a Presentation...
“Building and Scaling AI Applications with the Nx AI Manager,” a Presentation...“Building and Scaling AI Applications with the Nx AI Manager,” a Presentation...
“Building and Scaling AI Applications with the Nx AI Manager,” a Presentation...
Edge AI and Vision Alliance
 
みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...
みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...
みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...
名前 です男
 
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with SlackLet's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
shyamraj55
 
Building Production Ready Search Pipelines with Spark and Milvus
Building Production Ready Search Pipelines with Spark and MilvusBuilding Production Ready Search Pipelines with Spark and Milvus
Building Production Ready Search Pipelines with Spark and Milvus
Zilliz
 
Goodbye Windows 11: Make Way for Nitrux Linux 3.5.0!
Goodbye Windows 11: Make Way for Nitrux Linux 3.5.0!Goodbye Windows 11: Make Way for Nitrux Linux 3.5.0!
Goodbye Windows 11: Make Way for Nitrux Linux 3.5.0!
SOFTTECHHUB
 
20240605 QFM017 Machine Intelligence Reading List May 2024
20240605 QFM017 Machine Intelligence Reading List May 202420240605 QFM017 Machine Intelligence Reading List May 2024
20240605 QFM017 Machine Intelligence Reading List May 2024
Matthew Sinclair
 
Best 20 SEO Techniques To Improve Website Visibility In SERP
Best 20 SEO Techniques To Improve Website Visibility In SERPBest 20 SEO Techniques To Improve Website Visibility In SERP
Best 20 SEO Techniques To Improve Website Visibility In SERP
Pixlogix Infotech
 
20240609 QFM020 Irresponsible AI Reading List May 2024
20240609 QFM020 Irresponsible AI Reading List May 202420240609 QFM020 Irresponsible AI Reading List May 2024
20240609 QFM020 Irresponsible AI Reading List May 2024
Matthew Sinclair
 
Infrastructure Challenges in Scaling RAG with Custom AI models
Infrastructure Challenges in Scaling RAG with Custom AI modelsInfrastructure Challenges in Scaling RAG with Custom AI models
Infrastructure Challenges in Scaling RAG with Custom AI models
Zilliz
 
Climate Impact of Software Testing at Nordic Testing Days
Climate Impact of Software Testing at Nordic Testing DaysClimate Impact of Software Testing at Nordic Testing Days
Climate Impact of Software Testing at Nordic Testing Days
Kari Kakkonen
 
Introduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - CybersecurityIntroduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - Cybersecurity
mikeeftimakis1
 
Microsoft - Power Platform_G.Aspiotis.pdf
Microsoft - Power Platform_G.Aspiotis.pdfMicrosoft - Power Platform_G.Aspiotis.pdf
Microsoft - Power Platform_G.Aspiotis.pdf
Uni Systems S.M.S.A.
 
National Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practicesNational Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practices
Quotidiano Piemontese
 

Recently uploaded (20)

AI 101: An Introduction to the Basics and Impact of Artificial Intelligence
AI 101: An Introduction to the Basics and Impact of Artificial IntelligenceAI 101: An Introduction to the Basics and Impact of Artificial Intelligence
AI 101: An Introduction to the Basics and Impact of Artificial Intelligence
 
TrustArc Webinar - 2024 Global Privacy Survey
TrustArc Webinar - 2024 Global Privacy SurveyTrustArc Webinar - 2024 Global Privacy Survey
TrustArc Webinar - 2024 Global Privacy Survey
 
GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...
GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...
GraphSummit Singapore | Graphing Success: Revolutionising Organisational Stru...
 
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
GraphSummit Singapore | The Future of Agility: Supercharging Digital Transfor...
 
Removing Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software FuzzingRemoving Uninteresting Bytes in Software Fuzzing
Removing Uninteresting Bytes in Software Fuzzing
 
Serial Arm Control in Real Time Presentation
Serial Arm Control in Real Time PresentationSerial Arm Control in Real Time Presentation
Serial Arm Control in Real Time Presentation
 
Cosa hanno in comune un mattoncino Lego e la backdoor XZ?
Cosa hanno in comune un mattoncino Lego e la backdoor XZ?Cosa hanno in comune un mattoncino Lego e la backdoor XZ?
Cosa hanno in comune un mattoncino Lego e la backdoor XZ?
 
“Building and Scaling AI Applications with the Nx AI Manager,” a Presentation...
“Building and Scaling AI Applications with the Nx AI Manager,” a Presentation...“Building and Scaling AI Applications with the Nx AI Manager,” a Presentation...
“Building and Scaling AI Applications with the Nx AI Manager,” a Presentation...
 
みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...
みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...
みなさんこんにちはこれ何文字まで入るの?40文字以下不可とか本当に意味わからないけどこれ限界文字数書いてないからマジでやばい文字数いけるんじゃないの?えこ...
 
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with SlackLet's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
Let's Integrate MuleSoft RPA, COMPOSER, APM with AWS IDP along with Slack
 
Building Production Ready Search Pipelines with Spark and Milvus
Building Production Ready Search Pipelines with Spark and MilvusBuilding Production Ready Search Pipelines with Spark and Milvus
Building Production Ready Search Pipelines with Spark and Milvus
 
Goodbye Windows 11: Make Way for Nitrux Linux 3.5.0!
Goodbye Windows 11: Make Way for Nitrux Linux 3.5.0!Goodbye Windows 11: Make Way for Nitrux Linux 3.5.0!
Goodbye Windows 11: Make Way for Nitrux Linux 3.5.0!
 
20240605 QFM017 Machine Intelligence Reading List May 2024
20240605 QFM017 Machine Intelligence Reading List May 202420240605 QFM017 Machine Intelligence Reading List May 2024
20240605 QFM017 Machine Intelligence Reading List May 2024
 
Best 20 SEO Techniques To Improve Website Visibility In SERP
Best 20 SEO Techniques To Improve Website Visibility In SERPBest 20 SEO Techniques To Improve Website Visibility In SERP
Best 20 SEO Techniques To Improve Website Visibility In SERP
 
20240609 QFM020 Irresponsible AI Reading List May 2024
20240609 QFM020 Irresponsible AI Reading List May 202420240609 QFM020 Irresponsible AI Reading List May 2024
20240609 QFM020 Irresponsible AI Reading List May 2024
 
Infrastructure Challenges in Scaling RAG with Custom AI models
Infrastructure Challenges in Scaling RAG with Custom AI modelsInfrastructure Challenges in Scaling RAG with Custom AI models
Infrastructure Challenges in Scaling RAG with Custom AI models
 
Climate Impact of Software Testing at Nordic Testing Days
Climate Impact of Software Testing at Nordic Testing DaysClimate Impact of Software Testing at Nordic Testing Days
Climate Impact of Software Testing at Nordic Testing Days
 
Introduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - CybersecurityIntroduction to CHERI technology - Cybersecurity
Introduction to CHERI technology - Cybersecurity
 
Microsoft - Power Platform_G.Aspiotis.pdf
Microsoft - Power Platform_G.Aspiotis.pdfMicrosoft - Power Platform_G.Aspiotis.pdf
Microsoft - Power Platform_G.Aspiotis.pdf
 
National Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practicesNational Security Agency - NSA mobile device best practices
National Security Agency - NSA mobile device best practices
 

JS performance tools

  • 1. A long time ago… dovchar 2014
  • 2. ✦ 8 years in IT ✦ 4 years in SoftServe ✦ 1.5 years Application Architect ✦ Main language: Javascript ✦ Hobby language: Go ✦ Pacemaker conference ✦ Script’n’Code meet-up ✦ Open source (typescript grails, clio go, sonar qunit, kojak, jspro) dovcharlvivjs2014 Aboutme
  • 3. dovcharlvivks2014 Agenda ✦ About Project ✦ Memory leaks, how are you ✦ Why some actions so slow?! ✦ Start analyzing ✦ JS tools ✦ Chrome, iOS monitoring, Kojak, jsPro, PSI, Chrome remote debug ✦ Examples ✦ Questions?..
  • 4. ProjectStatistic ✦ 3 years development ✦ 10 scrum teams ✦ 59 modules ✦ 3200 javascript files ✦ 200.000 lines of code ✦ 1.226 total violations ✦ 70.3% code coverage ✦ 83.0% code health dovcharlvivjs2014
  • 6. iPad2 is falling down dovcharlvivjs2014
  • 7. Dima WTF…, Why some actions are so SLOW?! dovcharlvivjs2014
  • 9. StartAnalysing ✦ Include analytic tools: google analytics, New Relic, AppDynamics, etc ✦ BAs should prepare top 10-15 pages most used ✦ BAs + QC should prepare test workflows for those pages ✦ Prepare data for tests, infrastructure (load balancer, cdn, servers, db) very close to production ✦ Prepare test tools for testing and come to an agreement with the stakeholders (because they might be commercial, not free) ✦ Preliminary data gathering from one or two scenarios ✦ Need to teach your team how to work with tool set and manage its data ✦ Automate as much as you can dovcharlvivjs2014
  • 10. Tools ✦ Chrome dev tools ✦ Chrome remote debugger ✦ Xcode iOS monitoring ✦ AppDynamics UX plugin ✦ Google analytics ✦ Kojak ✦ KojakSync + jsPro ✦ PageSpead Insights (PSI API) dovcharlvivjs2014
  • 12. GoogleAnalytics ✦ Google Analytics is built on a powerful, easy-to-use reporting platform, so that you can decide what data you want to view and customize your reports, with just a few clicks ✦ Content reports help you understand which parts of your website are performing well and which pages are most popular so that you can create a better experience for your customers ✦ You can analyse how visitors interact with sharing features on your site (like the Google +1 button) and engage with your content across social platforms ✦ Google Analytics helps you measure the impact of mobile on your business ✦ Find out how many customers you're attracting, how much you're selling and how users are engaging with your site with Google Analytics' range of analysis features. ✦ Make the most of your advertising by learning how well your social, mobile, search and display ads are working dovcharlvivjs2014
  • 19. Memorysnapshotdovcharlvivjs2014 CD Tools -> Profiles -> Take Heap Snapshot
  • 20. TaskManager Menu -> Tools -> Task Manager dovcharlvivjs2014
  • 23. ✦ Where your heaviest loads originate ✦ Where your slowest end-user response times occur ✦ how performance varies by location ✦ how performance varies by client type, device, browser and browser version,network connection ✦ how performance varies by application and application version, operating system version, device, carrier for mobile apps ✦ what your slowest Web requests/Ajax requests are and what is causing the slowdown ✦ what your slowest mobile network requests are and what is causing the slowdown ✦ how application server performance impacts the performance of your web and mobile traffic AppDynamicsUXdovcharlvivjs2014
  • 25. WhoisKojak «Kojak is an American television series starring Telly Savalas as the title character, New York City Police Department Detective Lieutenant Theo Kojak. Taking the time slot of the popular Cannon series, moved one hour earlier, it aired on CBS from October 24, 1973, to March 18, 1978. In 1999 TV Guide ranked Theo Kojak number 18 on its 50 Greatest TV Characters of All Time list» Wikipedia dovcharlvivjs2014
  • 26. KojakJS Kojak is a simple utility that can help you figure out which of your JavaScript functions are running too slow. It tracks when your functions are called, how often they are called, how much time they are taking, how the functions were called. It can also track your ajax calls and help figure out how fast they are. What is Kojak JS? dovcharlvivjs2014
  • 27. Features ✦ Kojak helps you focus on the performance of your own code and eliminate the clutter ✦ Kojak is a tool that would remove all of the noise and clutter ✦ Kojak is a tool that was easy to configure and didn't force you to inject hooks all over my code ✦ The core of Kojak has no external dependencies ✦ We can easily integrate Kojak with Backbone, Angular or Ember ✦ Measure isolated time of your functions. IsolatedTime is how much cumulative time was spent inside the function itself ✦ Measure functions call count. Call count how often some functions has called. ✦ Tracking performance in between actions ✦ Tracking Network Requests dovcharlvivjs2014
  • 28. Explanation Aspect-Oriented Programming (AOP) is a programming paradigm that aims to increase modularity by allowing the separation of cross- cutting concerns. AOP forms a basis for aspect-oriented software development. dovcharlvivjs2014
  • 29. HowTo ✦ To use Kojak copy/download the Kojak.min.js file from github.com/theironcook/Kojak. Include it in the browser code you want to profile. ✦ Kojak needs to be told what code it is supposed to profile. You tell Kojak via the command: kConfig.setIncludedPakages(['packageA', ‘packageB’]); ✦ After you've told Kojak what it should are about and what to exclude you need to run this command: kInst.instrument(); ✦ Start tracking performance in between actions: run kInst.takeCheckpoint(); for creating checkpoint before actions begin. ✦ After doing some use cases run kRep.funcPerfAfterCheckpoint(); and collect isolated time and call count all functions has ran from last kInst.takeCheckpoint(); ✦ Kojak can also track all of your network ajax requests. To use the NetWatcher you must use jQuery. To enable run this command: kConfig.setEnableNetWatcher(true); and kRep.netCalls(); after dovcharlvivjs2014
  • 36. Kojak&jsPro KojakSync#1 KojakSync#2 KojakSync#N jsPro Visualization Storage dovcharlvivjs2014
  • 38. Kojak&jsPro ✦ To use KojakSync copy/download the Kojak.js file from github.com/dovchar/KojakSync. Include it in the browser code you want to profile ✦ Go to jspro.herokuapp.com ✦ Login with your github account -> your name -> my apps -> click «create new» button -> copy API Key and Secret Key ✦ Run Google Chrome with flags: —enable-memory-info --js-flags="--expose-gc" ✦ Enable kojak sync functionality: kConfig.sync('secretKey', ‘apiKey'); ✦ Todo all steps like with native Kojak for collect data dovcharlvivjs2014
  • 40. NextSteps ✦ Prepare good documentation ✦ Stabilize jsPro application (fix bugs) ✦ Extend functionality ✦ Integrate Google PSI API ✦ Integrate Chrome Remote Debugger ✦ Collect errors from UI ✦ Snapshots by User session for production usage ✦ Granular collecting data for prod mode dovcharlvivjs2014
  • 42. Links ✦ AppDynamics ✦ Google Analytics ✦ Chrome Dev Tools ✦ Kojak, KojakSync, jsPro ✦ pacemaker, script’n’code ✦ Sails.js Facebook Twitter Linkedin Gmail dovcharlvivjs2014