wood burning stoves 2.0*
The moose likes Developer Certification (SCJD/OCMJD) and the fly likes FBNS: with lock and unlock no need to synchronize Data.java? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Certification » Developer Certification (SCJD/OCMJD)
Bookmark "FBNS: with lock and unlock no need to synchronize Data.java?" Watch "FBNS: with lock and unlock no need to synchronize Data.java?" New topic
Author

FBNS: with lock and unlock no need to synchronize Data.java?

Ian Wark
Ranch Hand

Joined: Jun 28, 2004
Posts: 37
Hi.

I am looking at Mr. Habibe's coauthored book and the locking mechanism...

A lot has been said about this. So I'll be brief. If I follow the "one database instance per client" and use a locking mechanism that synchronizes on a static collection variable that keeps track of which records are locked, am I safe without ANY synchronized methods in Data.java?

I am only locking the write operations, and I am using RMI.
 
 
subject: FBNS: with lock and unlock no need to synchronize Data.java?
 
Similar Threads
Implementing Lock/Unlock
Data.java
For Max: Controller in MVC
Share parts of my choice.txt with javaranchers
NX: Extending or expanding the DB interface.