• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

URLyBird DB Locking

 
Cathal Mullan
Ranch Hand
Posts: 119
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hey Guys,

I have taken a look at some posts regarding the URLyBird DB locking, I see that people are returning lock keys to the front end.

I am wondering why people are doing this?

My plan is to have a thin client that connects to an RMI server. Behind this I will have a business layer.

In this business layer I was going to:

1. Get the lock for the record
2. Check the record has not been changed since it was retrieved
3. Update the record
4. Release the lock

So no returning lock keys to the front end.

Did anybody who passed the OCMJD do this too? Or am I missing something important?

cheers
 
Roel De Nijs
Sheriff
Posts: 9190
77
AngularJS Chrome Eclipse IDE Hibernate Java jQuery MySQL Database Spring Tomcat Server
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It all depends of course on the interface you've got. For example my interface does not have a lockCookie, so I had to come up with a slightly different approach. But for a thin client you don't need to pass the lockCookie back to the client, all the magic can happen on the server.
 
Cathal Mullan
Ranch Hand
Posts: 119
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hey Roel,

my services interface would be something like:



so no lock keys returned to the front end, seem ok to you?

cheers
 
Roel De Nijs
Sheriff
Posts: 9190
77
AngularJS Chrome Eclipse IDE Hibernate Java jQuery MySQL Database Spring Tomcat Server
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Lacks some business exceptions, but that's not the point here Seems ok to me
 
Cathal Mullan
Ranch Hand
Posts: 119
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Cheers for the advice, just want to make sure I don't get an automatic fail
 
Roel De Nijs
Sheriff
Posts: 9190
77
AngularJS Chrome Eclipse IDE Hibernate Java jQuery MySQL Database Spring Tomcat Server
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Just remember: I am not an accessor, so there is no guarantee that the given advice will not result in automatic failure. If you violate a must requirement, you'll fail (automatically). For all other decisions there is no good or wrong, just document your decisions in choices.txt and you'll be fine (and an OCMJD soon)
 
Cathal Mullan
Ranch Hand
Posts: 119
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hopefully

cheers
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic