JUDCon Berlin 2010 -  practical enterprise java performance tuning
Upcoming SlideShare
Loading in...5
×

Like this? Share it with your network

Share

JUDCon Berlin 2010 - practical enterprise java performance tuning

  • 1,051 views
Uploaded on

 

More in: Technology
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Be the first to comment
No Downloads

Views

Total Views
1,051
On Slideshare
1,050
From Embeds
1
Number of Embeds
1

Actions

Shares
Downloads
22
Comments
0
Likes
1

Embeds 1

http://www.linkedin.com 1

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
    No notes for slide

Transcript

  • 1.
  • 2. Practical Enterprise Java Performance Tuning
    Matt Brasier
    Principal Consultant, C2B2 Ltd
  • 3. Agenda
    Introduction
    Performance tuning toolbox
    Examples
    Summary
  • 4. Introduction
    Who Am I?
    Matt Brasier
    Principal Consultant at C2B2 Consulting
    10 years Java EE experience
    6 years as a consultant
  • 5. Introduction
    This talk
    Introduction to tools used
    Practical demonstrations
    Download the example application
    www.c2b2.co.uk/judcon/sampleapp.zip
  • 6. Performance consultant’s toolbox
  • 7. JBoss admin console
  • 8. JBoss admin console
    http://localhost:8080/admin-console
    Since JBoss 5
    Cut-down version of RHQ
  • 9. JBoss jmx-console
  • 10. JBoss jmx-console
    http://localhost:8080/jmx-console
    Dynamic view of JMX mbeans
    Information overload
    Fast if you know what you are looking for
    A few really useful features
  • 11. VisualVM
  • 12. VisualVM
    Distributed with JDK 6
    Successor to jconsole
    Install all the plugins!
    jvisualvm from the command line
  • 13. Command line JDK tools
    jps
    Process IDs of Java processes
    jstat
    JVM statistics for things such as GC
    jstack
    Thread dumps
    jhat
    Heap dump analysis
  • 14. Testing Tools
  • 15. JMeter
  • 16. JMeter
    http://jakarta.apache.org/jmeter/
    Load testing tool
    Easy to produce scripts
    Can record scripts from a browser
    Can run in distributed mode
  • 17. The Grinder
  • 18. The Grinder
    http://grinder.sourceforge.net/
    Load testing tool
    More complex scripts than Jmeter
    Jython based
    Better for extreme testing
  • 19. Live Demo
  • 20. Summary
    The JVM and JMX make a lot of information available
    The tools to get at the information are readily available
    All that you have to do is understand what it is telling you
  • 21. Hot method
    Repeated Thread dumps reveals one method appears frequently
    It is either occuring a lot or running slowly
  • 22. System.gc
    Frequent major garbage collections
    jstat shows a large GCT and System.gc as the previous GC cause
    VisualVM shows large proportion of CPU time spent garbage collecting
  • 23. Synchronization
    Thread dump reveals large number of threads blocked waiting for the same lock
  • 24. Key techniques
    Load testing
    Thread dumps
    Visual VM
    Swiss army knife of Java consultants
  • 25. Questions?
  • 26. Thank you