Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Lock on the same record and diff record ?

 
roy shao
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi,
if client A modified record No.1, and client B also modified record No.1, the B should be blocked,
and if Client B is modifying not record No.1, such as record No.2, then client B need not be blocked ?
is my understanding correct ? please clear my idea about it.
Thank you !
Roy
 
ruilin yang
Ranch Hand
Posts: 334
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes, You are right. This is so called "horirontal lock" scheme, which is more effecient.
 
roy shao
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thanks, then i will wonder this: if record No.1 lock and No2 lock is not mutex, at the file I/O level, when write to file, need thread safe ? i.e. write to No1, No.2 record at same time will bring any problem ?
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic