What's meaning of "book"?It means input into the "owner" field? or other operation?
Yes, you should allow the user to put an ID in that field, effectively flagging the record/row as booked. Your instructions should explain whether this is numeric or alphanumeric.
2.How to realize "Thread safety"? Synchronizing a hashmap object in the lock and unlock methods is having resolved the problem?[/QB]