Win a copy of AWS Security this week in the Cloud/Virtualization forum!
  • 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 all forums
this forum made possible by our volunteer staff, including ...
  • Campbell Ritchie
  • Paul Clapham
  • Jeanne Boyarsky
  • Junilu Lacar
  • Henry Wong
  • Ron McLeod
  • Devaka Cooray
  • Tim Cooke
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Frits Walraven
  • Tim Holloway
  • Carey Brown
  • Piet Souris
  • salvin francis
  • fred rosenberger

Other method should work when database is locked

Ranch Hand
Posts: 133
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I want to ask one question when you enters -1 record only seatbooking method should be blocked and message should be displayed that database is locked, but searching, deleting and record adding method's should work, I mean that only booking should be blocked nothing else on the database.
am i right.
Anurag Mishra
Ranch Hand
Posts: 200
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Since Sun specify only a 'write' lock in the specification I would think that you should be able to perform searches/lookups the database still. I don't believe the user should be able to remove records when the whole database is locked as this would constitute a 'write'. However, I would also interpret a 'write lock' on the entire database to mean that the user cannot add records either.
How have other people interpreted this?
Ranch Hand
Posts: 38
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes even i see it as only write lock.
Becoz in our assignment, we are just asked to lock dataBase when -1 is passed to lock() method.
And our lock() method is Write lock implementation only.
I don't see anywhere else where they have asked anything more than that.
will love to see other's view.
If you believe you can tell me what to think, I believe I can tell you where to go. Go read this tiny ad!
Devious Experiments for a Truly Passive Greenhouse!
    Bookmark Topic Watch Topic
  • New Topic