Skip to Main Content

Java Programming

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Singleton; synchronized vs. AtomicReference.compareAndSet()

807580Jan 14 2010 — edited Jan 14 2010
I stumbled on this link; [http://www.rockstarprogrammer.org/post/2006/oct/19/java-singletons-without-locks/]
which suggests the merits of AtomicReference.compareAndSet() are greatly exaggerated
at least in the context of singleton initialization.
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Feb 11 2010
Added on Jan 14 2010
15 comments
2,370 views