• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

locking the entire db??

 
subu ananthram
Ranch Hand
Posts: 102
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Howdy,
I am wondering if there is another way out of this sticky situation.
I have a file access class like many others that my Data class calls.
Now I synchronize on the random acces file instance which is static to my fileaccess class and there is only one instance of my file access class
the idea is so that one thread at a time plays with the raf and my file pointers dont go crazy .This will make the application perform badly since only one thread can do anything with the random access file ...Is there some other way of doing this...Please comment
Subu
 
Jeroen T Wenting
Ranch Hand
Posts: 1847
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Just make sure the synchronised blocks are as small as possible.
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic