Cant Enable Only one OPEN Stream on a file #319
-
Hi. I have a problem here. I don't want many streams to be opened for the same file at the same time. So I use semaphores. The semaphore waits before opening the stream in CreateNew function in Mirror and is Released in Close and Cleanup functions where streams are Closed. So my question is. Can a word file or ppt or another microsoft file that is in our Drive be opened having only one open stream at the same time? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Hi @MagaKhachatryan , This is a very hard requirement to achieve to only have one stream open on one file at a time. Depending on the reason why having the lock in Create, I would suggest reducing the locking scope to only where you need it (like write and read if it is to protect data). |
Beta Was this translation helpful? Give feedback.
Hi @MagaKhachatryan ,
This is a very hard requirement to achieve to only have one stream open on one file at a time.
It is not only word that will try to access the word file but any application on the system which no one has control one.
Depending on the reason why having the lock in Create, I would suggest reducing the locking scope to only where you need it (like write and read if it is to protect data).