Java Performance Tuning

Java(TM) - see bottom of page

|home |services |training |newsletter |tuning tips |tool reports |articles |resources |about us |site map |contact us |
Tools: | GC log analysers| Multi-tenancy tools| Books| SizeOf| Thread analysers|

Our valued sponsors who help make this site possible
New Relic: Try free w/ production profiling and get a free shirt! 

Site24x7: Java Method-Level Tracing into Transactions @ $12/Month/JVM. Sign Up! 

News January 2015

jKool for DevOps
Light up your Apps & get a cool t-shirt

JProfiler
Get rid of your performance problems and memory leaks!


Java Performance Training Courses
COURSES AVAILABLE NOW. We can provide training courses to handle all your Java performance needs

Java Performance Tuning, 2nd ed
The classic and most comprehensive book on tuning Java

Java Performance Tuning Newsletter
Your source of Java performance news. Subscribe now!
Enter email:


New Relic
New Relic: Try free w/ production profiling and get a free shirt!

Site24x7
Site24x7: Java Method-Level Tracing into Transactions @ $12/Month/JVM. Sign Up!


jKool for DevOps
Light up your Apps & get a cool t-shirt

JProfiler
Get rid of your performance problems and memory leaks!


Back to newsletter 170 contents

I love the fascinating new items my newsletters teach or remind me. In this month's extracted tips from the linked articles I learned:

A note from this newsletter's sponsor

Get total visibility in just 15 minutes with AppDynamics PRO,
A performance monitoring tool for Java/.NET apps.
It installs in minutes. Start your FREE TRIAL today.

1. You can back any (ExecutorService) thread pool with a SynchronousQueue which makes it queueless (it only accepts a task if there is a free thread);

2. You can use AtomicIntegerFieldUpdater for lazily atomically updating volatiles (volatile++ is not atomic, AtomicIntegerFieldUpdater.getAndIncrement(object) is);

3. All Java 8 parallel streams across the JVM globally share the same thread pool by default - I can immediately see this is something that will cause contention issues in the future, so you should know it so it's easily diagnosed.

4. I've used the following statement every time I look at a heap dump, but funnily enough I've never seen it written down in this concise way: When there is a large difference in retained memory between a parent and child object, this is a good candidate for the holder of a memory leak.

5. Change the thread name to show the resources and data context it is operating in so that if you take a trace using jstack, you get the context as well as the operating stack - this makes diagnosing what it is doing much easier (you can keep changing the thread name, though it's probably not useful to change it too often).

6. Cancelling running tasks asynchronously is hard - you need to think about how that can happen if your task is in a non-interruptible call like using a resource (often that requires another thread closing that resource so that the task can exit the call and terminate).

Now on to all our usual sections: links to tools, articles, news, talks and as ever, all the extracted tips from all of this month's referenced articles including those gems above.

A note from this newsletter's sponsor

Site24x7.com : Deep dive Application Performance Monitoring
Fix performance issues with Java, .NET and Ruby platforms.
*** Monitor one app instance starting at $9 ***.

News

Java performance tuning related news.

Tools

Java performance tuning related tools.

A note from this newsletter's sponsor

New Relic - Try New Relic today and get your free Data Nerd shirt!
Free SaaS APM tool to monitor, troubleshoot, and tune apps
running on Websphere, Weblogic, Tomcat, Jetty, JBoss, Solr, Resin

Articles

Jack Shirazi


Back to newsletter 170 contents


Last Updated: 2017-06-27
Copyright © 2000-2017 Fasterj.com. All Rights Reserved.
All trademarks and registered trademarks appearing on JavaPerformanceTuning.com are the property of their respective owners.
Java is a trademark or registered trademark of Oracle Corporation in the United States and other countries. JavaPerformanceTuning.com is not connected to Oracle Corporation and is not sponsored by Oracle Corporation.
URL: http://www.JavaPerformanceTuning.com/news/news170.shtml
RSS Feed: http://www.JavaPerformanceTuning.com/newsletters.rss
Trouble with this page? Please contact us