Geek Explains: Java, J2EE, Oracle, Puzzles, and Problem Solving!
Wednesday, May 14, 2008
Synchronized Block vs Synchronized Method
Synchronized block retains the lock for comparatively smaller period of time as compared to synchronized methods, at least in most of the cases. So, try to use synchronized blocks as long as it doesn’t affect the business requirement.
No comments:
Post a Comment
‹
›
Home
View web version
No comments:
Post a Comment