|
Re: [CDO] Locking while editor is open to reduce possibilities of conflict [message #1184484 is a reply to message #1184468] |
Wed, 13 November 2013 13:40 |
|
Hi, Leonid,
The server releases all locks held by a session when that session goes
away for any reason. You can try this, yourself, by killing the client
process and then issuing a "cdo locks" command on server's OSGi console.
I don't know whether automatically locking the resource is a good or a
poor practice. It depends on whether it works for your use cases and
it really makes sense to freeze other users out of editing. BTW, how
does the editor present itself when it cannot obtain the locks it
needs? That could present some usability issues ...
I think Eike has been doing a good deal of work on making merge work
better for transaction conflict resolution, which may possibly relieve
your need for locks. Doubtless he can be more helpful.
HTH,
Christian
On 2013-11-13 13:21:34 +0000, Leonid Ripeynih said:
> Hi there!
>
> I'd like to lock resources (acqure write lock) to resources in
> repository when editor (for resource) is opened, and release it when
> it's disposed. All to prevent concurrent modification of resource
> between multiple users.
> It works fine by now, but here is some questions, just to make sure:
> 1. Will the lock be released upon session close (when an editor's
> dispose method is not given possibility to act: computer reboot, kill
> -9 e.t.c)
> 2. Is it generally a good practice, and is there other (maybe built-in)
> methods to achive same functionality?
>
> Many thanks in advance.
|
|
|
Powered by
FUDForum. Page generated in 0.03640 seconds