• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

managing connection per lock is necessary ??

 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
for lock/unlock part in the specs its mentioned "
the unlock method simply removes the lock from the specified record, if an attempt is made to unlock a record that has not been locked by this connection, then no action is be taken. "
this action could'nt occur and shouldnt be by the spec. why ? becuse its mentioned in the spec. " the lock method block until a requested lock can be applied" , and so it cannot be unlocked unitl its locked before, and trivially unlock comes after lock, so its for sure only the record that lock is the one that can unlock, since if others are to lock what is locked they have to wait. I think the complexity of monitoring what connection for a lock is not neccessary. although its mentioned in the specs. I think this part is trivial and wont add something to the locking programming. and so connection class/object is not necessary, and the lock/unlock methods signature mentioned in the specs are enough. any comment ??
 
Ranch Hand
Posts: 3451
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
If you want to get the best help and advice on Java anywhere, you need to change your display name to a first and last name.
Read thru this thread to see some opinions on this matter:
Unlock ignoring bogus requests

Michael Morris
 
devx22002
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks a lot, I believe this reference is useful.
Thanks.
 
ranger
Posts: 17347
11
Mac IntelliJ IDE Spring
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
"devx22002"-
Welcome to the JavaRanch! Please adjust your displayed name to meet the
JavaRanch Naming Policy.
You can change it
here.
Thanks! and welcome to the JavaRanch!
Mark
 
It's a beautiful day in this neighborhood - Fred Rogers. Tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic