This has probably been asked before but I guess locking will not be required for create(). There is really nothing to lock. However, the actual writing of the data to the database will be sychronized as such the database itself need not be "locked" --- Is this correct?
X-Mas and Happy New year to everyone
posted 11 years ago
I didn't use locking with create(). I keep a list containing record numbers of deleted records. I synchronize on this list, create the record at the record number contained in the first index of the list, and if successful, remove this record number from the list of deleted record numbers. If the list of deleted records is empty, I simply add the record to the end of the file.
B.S. University of Wisconsin<br />SCJP 1.4 (85%)<br />SCJD 1.4 (92%) B&S Contractors