Managing Volatility in the Java World (developerWorks)
[Posted June 19, 2007 by ris]
Managing Volatility in the Java World (developerWorks)
[Press] Posted Jun 19, 2007 17:30 UTC (Tue) by ris
IBM developerWorks looks
at volatility in Java. "The Java language contains two intrinsic
synchronization mechanisms: synchronized blocks (and methods) and volatile
variables. Both are provided for the purpose of rendering code
thread-safe. Volatile variables are the weaker (but sometimes simpler or
less expensive) of the two -- but also easier to use incorrectly. In this
installment of Java theory and practice, Brian Goetz explores some patterns
for using volatile variables correctly and offers some warnings about the
limits of its applicability."
Comments (2 posted)