Best Practices in Developing High Performance Java Applications A Perspective Keynote at Silicon...

17
Best Practices in Developing High Performance Java Applications A Perspective Keynote at Silicon India Rajgopal Kishore Vice President and Global Head of BI & Analytics, HCL Technologies [email protected] [email protected]

Transcript of Best Practices in Developing High Performance Java Applications A Perspective Keynote at Silicon...

Page 1: Best Practices in Developing High Performance Java Applications A Perspective Keynote at Silicon India Rajgopal Kishore Vice President and Global Head.

Best Practices in Developing High Performance Java ApplicationsA Perspective

Keynote at Silicon India

Rajgopal KishoreVice President and Global Head of BI & Analytics,

HCL [email protected]

[email protected]

Page 2: Best Practices in Developing High Performance Java Applications A Perspective Keynote at Silicon India Rajgopal Kishore Vice President and Global Head.

Agenda

• Business Implication of System Performance

• Understanding Performance Requirements

• Sharing Some War Stories

• Best Practices

Page 3: Best Practices in Developing High Performance Java Applications A Perspective Keynote at Silicon India Rajgopal Kishore Vice President and Global Head.

Business Implications of System Performance

• We all want a nice user experience

• We won’t tolerate slow pages (we have options); lesser still any downtime– 500 ms slower = 20% drop in traffic (Google)– 100 ms slower = 1% drop in sales (Amazon)

• Slower Warehouse management system – lower warehouse throughput!

• Any downtime in a trading system - $m lost

Page 4: Best Practices in Developing High Performance Java Applications A Perspective Keynote at Silicon India Rajgopal Kishore Vice President and Global Head.

What is Performance? Is a subset of NFR…

• On-line applications -– Response time– Maintaining response time with increasing load –

scalability– Throughput– Handles user expectations/frustration– Availability

• Batch applications– Runs in the batch window – which is constantly shrinking!– Does not slow down other on-line work to an

unacceptable level

Page 5: Best Practices in Developing High Performance Java Applications A Perspective Keynote at Silicon India Rajgopal Kishore Vice President and Global Head.

Biggest Cause of Performance Failures..

• Not understanding performance requirements (implicit, explicit, real, or expectation)

• Not setting expectations early enough

• Not understanding and explaining trade-offs between performance and $ (infrastructure), and time

Page 6: Best Practices in Developing High Performance Java Applications A Perspective Keynote at Silicon India Rajgopal Kishore Vice President and Global Head.

Performance Requirements Capture – Sample

• The application will be optimized for high throughput. Traffic is to be tested for 250 concurrent users and 24/7 operations

• All simple transactions will have a response time of less than 5 seconds. Complex transactions will have a response time of 15 seconds

• The response time of all the pages would be less than 3 seconds

Page 7: Best Practices in Developing High Performance Java Applications A Perspective Keynote at Silicon India Rajgopal Kishore Vice President and Global Head.

Consequently …

• Performance requirements captured are insubstantial; Work pattern and user behavior is not understood

• Infrastructure is suggested with out any basis

• No performance benchmarking done till the system integration phase of the project

• Benchmarking goals are not defined

Page 8: Best Practices in Developing High Performance Java Applications A Perspective Keynote at Silicon India Rajgopal Kishore Vice President and Global Head.

What are Performance Requirements? - Multiple dimensions

• Infrastructure model– Boxes, routers, IP splitters, CPUs, RAM, bandwidth

• Transaction model– Transaction arrivals rates, think time, variation across the day

• External transaction model– Any messages, file uploads

• Data retention model– # years, hot, warm and cold areas, read-only or read-write

Page 9: Best Practices in Developing High Performance Java Applications A Perspective Keynote at Silicon India Rajgopal Kishore Vice President and Global Head.

Some War Stories

Page 10: Best Practices in Developing High Performance Java Applications A Perspective Keynote at Silicon India Rajgopal Kishore Vice President and Global Head.

Deathcare Major in the US …

• 15000 users• Complex application• Low bandwidth network – 128K• 7 seconds response time needs – set after a

discussion

Page 11: Best Practices in Developing High Performance Java Applications A Perspective Keynote at Silicon India Rajgopal Kishore Vice President and Global Head.

Major Retailer …

• Large and complex application for assortment planning

• Board level visibility

Page 12: Best Practices in Developing High Performance Java Applications A Perspective Keynote at Silicon India Rajgopal Kishore Vice President and Global Head.

Large fashion Retailer…

• Big brand• Wanted a 2 second response time for a

planning application

Page 13: Best Practices in Developing High Performance Java Applications A Perspective Keynote at Silicon India Rajgopal Kishore Vice President and Global Head.

At a mid size Telecom company…

• Need to “validate” capacity plan of their boxes for a MLM solution roll-out

Page 14: Best Practices in Developing High Performance Java Applications A Perspective Keynote at Silicon India Rajgopal Kishore Vice President and Global Head.

Summarizing Some Best Practices in development high performance apps…

What you will not get on the Internet

Page 15: Best Practices in Developing High Performance Java Applications A Perspective Keynote at Silicon India Rajgopal Kishore Vice President and Global Head.

Best Practices …

• Understand, set and control expectations.

• Always attempt to understand real business need as opposed to articulated performance requirements

• Big picture first – infrastructure capacity planning

• Then optimize the application – create an app where the only bottleneck is the infrastructure …

Page 16: Best Practices in Developing High Performance Java Applications A Perspective Keynote at Silicon India Rajgopal Kishore Vice President and Global Head.

Best Practices …

• Abstraction is not good for performance …. Including Virtualization!!!

• Do not use the same APIS for batch and on-line programs

• Early stage performance prototyping….

Page 17: Best Practices in Developing High Performance Java Applications A Perspective Keynote at Silicon India Rajgopal Kishore Vice President and Global Head.

Questions!