Hi Sergei 2013/2/22 Sergey Spiridonov <[email protected]>
> Hi Dimitris > > > On 02/22/2013 11:03 AM, Dimitris Servis wrote: > > > I am not sure what you mean with internal/external lock >> > > One way to implement locking would be the following: > > before opening hdf5 file /somepath/somefile.hdf create an external file > /somepath/.somefile.hdf.lock$$**$ and lock it. After closing hdf5 file, > delete and unlock this external file. > > I understood you as you did it this way, because you wrote about "waiting > for a shared lock on a different handle". > > OK now it's clear. No I did not do it this way. The reason is that you may not have the rights to create an external lock file. If you can guarantee you do it is indeed the best solution. That was my first implementation until I discovered I cannot guarantee the proper user rights all the time. When I wrote "waiting for a shared lock on a different handle" I meant another file handle to the same file but not the file handle that HDF5 uses to write. Unfortunately you cannot lock one handle and write with another from the same process, at least on Windows if I recall correctly. Kind Regards Dimitris Servis
_______________________________________________ Hdf-forum is for HDF software users discussion. [email protected] http://mail.hdfgroup.org/mailman/listinfo/hdf-forum_hdfgroup.org
