Great ways to improve java performance

B Sai Prasad
B Sai PrasadSenior Manager of Learning and Development em Cognizant Technology Solutions
www.sainivas.com,[object Object],1,[object Object]
Why performance is so important?,[object Object],Java,[object Object],2,[object Object],www.sainivas.com,[object Object]
Imagine a world where everything is UNLIMITED,[object Object],3,[object Object],www.sainivas.com,[object Object]
Sorry!!You are in a world where everything is LIMITED,[object Object],4,[object Object],www.sainivas.com,[object Object]
Why performance matters?,[object Object],90% of requirements are complex,[object Object],50% of apps share the same server,[object Object],10% increase in end users every day,[object Object],Performance should be planned initially and                  not inspected later.,[object Object],5,[object Object],www.sainivas.com,[object Object]
Great ways to improveJava Performance,[object Object],By B. Sai Prasad,[object Object],6,[object Object],www.sainivas.com,[object Object],Simple,[object Object]
Introduction,[object Object],Java Puzzles,[object Object],Short program,[object Object],Where is the issue?,[object Object],How to fix?,[object Object],What did you learn?,[object Object],7,[object Object],www.sainivas.com,[object Object]
Puzzle #1,[object Object],8,[object Object],www.sainivas.com,[object Object]
Moral #1new operator creates a new object,[object Object],“new operator can be avoided by re-using byte arrays, or re-using objects”,[object Object],9,[object Object],www.sainivas.com,[object Object]
Puzzle #2,[object Object],10,[object Object],www.sainivas.com,[object Object]
Moral #2Creating a Double from a string takes about 15 times than from a number,[object Object],“Use primitive data types for constructors rather than String objects.”,[object Object],11,[object Object],www.sainivas.com,[object Object]
Puzzle #3,[object Object],12,[object Object],www.sainivas.com,[object Object]
Moral #3length() call in a tight loop can hit performance,[object Object],“String length is pre-computed, stored in a local variable and used it in a tight loop”,[object Object],13,[object Object],www.sainivas.com,[object Object]
Puzzle #4,[object Object],14,[object Object],www.sainivas.com,[object Object]
Moral #4Default constructor is added automatically by compiler.,[object Object],“Generated constructor invokes the super class constructor.”,[object Object],15,[object Object],www.sainivas.com,[object Object]
Puzzle #5,[object Object],16,[object Object],www.sainivas.com,[object Object]
Moral #5Minimize method calls by method inlining,[object Object],“Inlining is done by expanding the inlined method’s code in the code that calls the method”,[object Object],17,[object Object],www.sainivas.com,[object Object]
Puzzle #6,[object Object],18,[object Object],www.sainivas.com,[object Object]
Moral #6System.arraycopy()efficiently copies one array to another,[object Object],“For very short arrays, use of this method may be counterproductive, because of overhead in actually calling the method”,[object Object],19,[object Object],www.sainivas.com,[object Object]
Puzzle #7,[object Object],20,[object Object],www.sainivas.com,[object Object]
Moral #7BufferedReader reads characters in chunks,[object Object],“the read() method found in BufferedReader simply returns characters from a buffer”,[object Object],21,[object Object],www.sainivas.com,[object Object]
Puzzle #8,[object Object],22,[object Object],www.sainivas.com,[object Object]
Moral #8Reuse. Reuse. Reuse.,[object Object],“It is better to reuse the java libraries than creating something new”,[object Object],23,[object Object],www.sainivas.com,[object Object]
Video,[object Object],www.sainivas.com,[object Object],24,[object Object]
1 de 24

Recomendados

The Internet Is Slowing Down, Fast por
The Internet Is Slowing Down, FastThe Internet Is Slowing Down, Fast
The Internet Is Slowing Down, FastChristian Bochicchio
365 visualizações31 slides
DevOpsGirls at TConf 2019 por
DevOpsGirls at TConf 2019DevOpsGirls at TConf 2019
DevOpsGirls at TConf 2019Theresa Neate
287 visualizações52 slides
20190919 backbase why_do_we_automate por
20190919 backbase why_do_we_automate20190919 backbase why_do_we_automate
20190919 backbase why_do_we_automateBas Dijkstra
78 visualizações33 slides
"The Future of Machine Learning & JavaScript"Asim Hussain por
"The Future of Machine Learning & JavaScript"Asim Hussain"The Future of Machine Learning & JavaScript"Asim Hussain
"The Future of Machine Learning & JavaScript"Asim HussainJulia Cherniak
927 visualizações60 slides
Bag Of Tricks From Iusethis por
Bag Of Tricks From IusethisBag Of Tricks From Iusethis
Bag Of Tricks From IusethisMarcus Ramberg
761 visualizações84 slides
Microservices and the Cloud - DevOps Cardiff Meetup por
Microservices and the Cloud - DevOps Cardiff MeetupMicroservices and the Cloud - DevOps Cardiff Meetup
Microservices and the Cloud - DevOps Cardiff MeetupMarc Cluet
5.1K visualizações46 slides

Mais conteúdo relacionado

Similar a Great ways to improve java performance

Are you ready for cloud-native Java? por
Are you ready for cloud-native Java?Are you ready for cloud-native Java?
Are you ready for cloud-native Java?Graham Charters
347 visualizações76 slides
ASP.NET Quick Wins - 20 Tips and Tricks To Shift Your Application into High Gear por
ASP.NET Quick Wins - 20 Tips and Tricks To Shift Your Application into High GearASP.NET Quick Wins - 20 Tips and Tricks To Shift Your Application into High Gear
ASP.NET Quick Wins - 20 Tips and Tricks To Shift Your Application into High GearKevin Griffin
1.5K visualizações109 slides
Stop using Nagios (so it can die peacefully) por
Stop using Nagios (so it can die peacefully)Stop using Nagios (so it can die peacefully)
Stop using Nagios (so it can die peacefully)Andy Sykes
232.5K visualizações37 slides
DataStax: How to Roll Cassandra into Production Without Losing your Health, M... por
DataStax: How to Roll Cassandra into Production Without Losing your Health, M...DataStax: How to Roll Cassandra into Production Without Losing your Health, M...
DataStax: How to Roll Cassandra into Production Without Losing your Health, M...DataStax Academy
1K visualizações30 slides
Wed-12-05pm-box-salmanahmed por
Wed-12-05pm-box-salmanahmedWed-12-05pm-box-salmanahmed
Wed-12-05pm-box-salmanahmedSalman Ahmed
638 visualizações38 slides
Cypress por
CypressCypress
CypressJonathan de Britto Sedrez
391 visualizações15 slides

Similar a Great ways to improve java performance(20)

Are you ready for cloud-native Java? por Graham Charters
Are you ready for cloud-native Java?Are you ready for cloud-native Java?
Are you ready for cloud-native Java?
Graham Charters347 visualizações
ASP.NET Quick Wins - 20 Tips and Tricks To Shift Your Application into High Gear por Kevin Griffin
ASP.NET Quick Wins - 20 Tips and Tricks To Shift Your Application into High GearASP.NET Quick Wins - 20 Tips and Tricks To Shift Your Application into High Gear
ASP.NET Quick Wins - 20 Tips and Tricks To Shift Your Application into High Gear
Kevin Griffin1.5K visualizações
Stop using Nagios (so it can die peacefully) por Andy Sykes
Stop using Nagios (so it can die peacefully)Stop using Nagios (so it can die peacefully)
Stop using Nagios (so it can die peacefully)
Andy Sykes232.5K visualizações
DataStax: How to Roll Cassandra into Production Without Losing your Health, M... por DataStax Academy
DataStax: How to Roll Cassandra into Production Without Losing your Health, M...DataStax: How to Roll Cassandra into Production Without Losing your Health, M...
DataStax: How to Roll Cassandra into Production Without Losing your Health, M...
DataStax Academy1K visualizações
Wed-12-05pm-box-salmanahmed por Salman Ahmed
Wed-12-05pm-box-salmanahmedWed-12-05pm-box-salmanahmed
Wed-12-05pm-box-salmanahmed
Salman Ahmed638 visualizações
Tis The Season: Load Testing Tips and Checklist for Retail Seasonal Readiness por SOASTA
Tis The Season: Load Testing Tips and Checklist for Retail Seasonal ReadinessTis The Season: Load Testing Tips and Checklist for Retail Seasonal Readiness
Tis The Season: Load Testing Tips and Checklist for Retail Seasonal Readiness
SOASTA 1.4K visualizações
Tis The Season: Load Testing Tips and Checklist for Retail Seasonal Readiness por SOASTA
Tis The Season: Load Testing Tips and Checklist for Retail Seasonal ReadinessTis The Season: Load Testing Tips and Checklist for Retail Seasonal Readiness
Tis The Season: Load Testing Tips and Checklist for Retail Seasonal Readiness
SOASTA1.7K visualizações
Machine learning pipeline por Vadym Kuzmenko
Machine learning pipelineMachine learning pipeline
Machine learning pipeline
Vadym Kuzmenko230 visualizações
Chaining the Beast - Testing Wonder Applications in the Real World por WO Community
Chaining the Beast - Testing Wonder Applications in the Real WorldChaining the Beast - Testing Wonder Applications in the Real World
Chaining the Beast - Testing Wonder Applications in the Real World
WO Community1.1K visualizações
MonoRails - GoGaRuCo 2012 por jackdanger
MonoRails - GoGaRuCo 2012MonoRails - GoGaRuCo 2012
MonoRails - GoGaRuCo 2012
jackdanger1.3K visualizações
ASP .NET MVC - best practices por Bohdan Pashkovskyi
ASP .NET MVC - best practicesASP .NET MVC - best practices
ASP .NET MVC - best practices
Bohdan Pashkovskyi390 visualizações
Keeping Rails on the Tracks por RubyX
Keeping Rails on the TracksKeeping Rails on the Tracks
Keeping Rails on the Tracks
RubyX2.7K visualizações
Increasing velocity via serless semantics por Kfir Bloch
Increasing velocity via serless semanticsIncreasing velocity via serless semantics
Increasing velocity via serless semantics
Kfir Bloch239 visualizações
Can you do DevOps in SAP (DevOps -> SAP) por Chris Kernaghan
Can you do DevOps in SAP (DevOps -> SAP)Can you do DevOps in SAP (DevOps -> SAP)
Can you do DevOps in SAP (DevOps -> SAP)
Chris Kernaghan1.7K visualizações
Developer Week por Docker, Inc.
Developer WeekDeveloper Week
Developer Week
Docker, Inc.566 visualizações
How fast can you onboard a new team member with VAGRANT ? por Vivek Parihar
How fast can you onboard a new team member with VAGRANT ?How fast can you onboard a new team member with VAGRANT ?
How fast can you onboard a new team member with VAGRANT ?
Vivek Parihar1.1K visualizações
Real World Single Page App - A Knockout Case Study por housecor
Real World Single Page App - A Knockout Case StudyReal World Single Page App - A Knockout Case Study
Real World Single Page App - A Knockout Case Study
housecor1.8K visualizações
Ruby For Startups por Mike Subelsky
Ruby For StartupsRuby For Startups
Ruby For Startups
Mike Subelsky1.4K visualizações
Enterprise Strength Mobile JavaScript por Troy Miles
Enterprise Strength Mobile JavaScriptEnterprise Strength Mobile JavaScript
Enterprise Strength Mobile JavaScript
Troy Miles11K visualizações

Último

Narration ppt.pptx por
Narration  ppt.pptxNarration  ppt.pptx
Narration ppt.pptxTARIQ KHAN
131 visualizações24 slides
Are we onboard yet University of Sussex.pptx por
Are we onboard yet University of Sussex.pptxAre we onboard yet University of Sussex.pptx
Are we onboard yet University of Sussex.pptxJisc
93 visualizações7 slides
Narration lesson plan.docx por
Narration lesson plan.docxNarration lesson plan.docx
Narration lesson plan.docxTARIQ KHAN
108 visualizações11 slides
Psychology KS4 por
Psychology KS4Psychology KS4
Psychology KS4WestHatch
76 visualizações4 slides
ANATOMY AND PHYSIOLOGY UNIT 1 { PART-1} por
ANATOMY AND PHYSIOLOGY UNIT 1 { PART-1}ANATOMY AND PHYSIOLOGY UNIT 1 { PART-1}
ANATOMY AND PHYSIOLOGY UNIT 1 { PART-1}DR .PALLAVI PATHANIA
244 visualizações195 slides
American Psychological Association 7th Edition.pptx por
American Psychological Association  7th Edition.pptxAmerican Psychological Association  7th Edition.pptx
American Psychological Association 7th Edition.pptxSamiullahAfridi4
82 visualizações8 slides

Último(20)

Narration ppt.pptx por TARIQ KHAN
Narration  ppt.pptxNarration  ppt.pptx
Narration ppt.pptx
TARIQ KHAN131 visualizações
Are we onboard yet University of Sussex.pptx por Jisc
Are we onboard yet University of Sussex.pptxAre we onboard yet University of Sussex.pptx
Are we onboard yet University of Sussex.pptx
Jisc93 visualizações
Narration lesson plan.docx por TARIQ KHAN
Narration lesson plan.docxNarration lesson plan.docx
Narration lesson plan.docx
TARIQ KHAN108 visualizações
Psychology KS4 por WestHatch
Psychology KS4Psychology KS4
Psychology KS4
WestHatch76 visualizações
ANATOMY AND PHYSIOLOGY UNIT 1 { PART-1} por DR .PALLAVI PATHANIA
ANATOMY AND PHYSIOLOGY UNIT 1 { PART-1}ANATOMY AND PHYSIOLOGY UNIT 1 { PART-1}
ANATOMY AND PHYSIOLOGY UNIT 1 { PART-1}
DR .PALLAVI PATHANIA244 visualizações
American Psychological Association 7th Edition.pptx por SamiullahAfridi4
American Psychological Association  7th Edition.pptxAmerican Psychological Association  7th Edition.pptx
American Psychological Association 7th Edition.pptx
SamiullahAfridi482 visualizações
Gopal Chakraborty Memorial Quiz 2.0 Prelims.pptx por Debapriya Chakraborty
Gopal Chakraborty Memorial Quiz 2.0 Prelims.pptxGopal Chakraborty Memorial Quiz 2.0 Prelims.pptx
Gopal Chakraborty Memorial Quiz 2.0 Prelims.pptx
Debapriya Chakraborty625 visualizações
discussion post.pdf por jessemercerail
discussion post.pdfdiscussion post.pdf
discussion post.pdf
jessemercerail130 visualizações
Sociology KS5 por WestHatch
Sociology KS5Sociology KS5
Sociology KS5
WestHatch65 visualizações
11.28.23 Social Capital and Social Exclusion.pptx por mary850239
11.28.23 Social Capital and Social Exclusion.pptx11.28.23 Social Capital and Social Exclusion.pptx
11.28.23 Social Capital and Social Exclusion.pptx
mary850239291 visualizações
The Open Access Community Framework (OACF) 2023 (1).pptx por Jisc
The Open Access Community Framework (OACF) 2023 (1).pptxThe Open Access Community Framework (OACF) 2023 (1).pptx
The Open Access Community Framework (OACF) 2023 (1).pptx
Jisc107 visualizações
ISO/IEC 27001 and ISO/IEC 27005: Managing AI Risks Effectively por PECB
ISO/IEC 27001 and ISO/IEC 27005: Managing AI Risks EffectivelyISO/IEC 27001 and ISO/IEC 27005: Managing AI Risks Effectively
ISO/IEC 27001 and ISO/IEC 27005: Managing AI Risks Effectively
PECB 574 visualizações
EIT-Digital_Spohrer_AI_Intro 20231128 v1.pptx por ISSIP
EIT-Digital_Spohrer_AI_Intro 20231128 v1.pptxEIT-Digital_Spohrer_AI_Intro 20231128 v1.pptx
EIT-Digital_Spohrer_AI_Intro 20231128 v1.pptx
ISSIP359 visualizações
Drama KS5 Breakdown por WestHatch
Drama KS5 BreakdownDrama KS5 Breakdown
Drama KS5 Breakdown
WestHatch73 visualizações
Use of Probiotics in Aquaculture.pptx por AKSHAY MANDAL
Use of Probiotics in Aquaculture.pptxUse of Probiotics in Aquaculture.pptx
Use of Probiotics in Aquaculture.pptx
AKSHAY MANDAL95 visualizações
ACTIVITY BOOK key water sports.pptx por Mar Caston Palacio
ACTIVITY BOOK key water sports.pptxACTIVITY BOOK key water sports.pptx
ACTIVITY BOOK key water sports.pptx
Mar Caston Palacio511 visualizações
Class 10 English notes 23-24.pptx por TARIQ KHAN
Class 10 English notes 23-24.pptxClass 10 English notes 23-24.pptx
Class 10 English notes 23-24.pptx
TARIQ KHAN125 visualizações
MercerJesse2.1Doc.pdf por jessemercerail
MercerJesse2.1Doc.pdfMercerJesse2.1Doc.pdf
MercerJesse2.1Doc.pdf
jessemercerail142 visualizações

Great ways to improve java performance

  • 1.
  • 2.
  • 3.
  • 4.
  • 5.
  • 6.
  • 7.
  • 8.
  • 9.
  • 10.
  • 11.
  • 12.
  • 13.
  • 14.
  • 15.
  • 16.
  • 17.
  • 18.
  • 19.
  • 20.
  • 21.
  • 22.
  • 23.
  • 24.