git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Locking the repository
@ 2005-05-06 12:31 Thomas Glanzmann
  2005-05-06 16:15 ` Linus Torvalds
  0 siblings, 1 reply; 2+ messages in thread
From: Thomas Glanzmann @ 2005-05-06 12:31 UTC (permalink / raw)
  To: GIT

Hello,
I need a way to lock a repository for certain actions. What can I use to
obtain this? Is there a way to use rsync for that? It should also be
NFS-safe. Are there are any classic unix tools that I can use for this?

	Thomas

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Locking the repository
  2005-05-06 12:31 Locking the repository Thomas Glanzmann
@ 2005-05-06 16:15 ` Linus Torvalds
  0 siblings, 0 replies; 2+ messages in thread
From: Linus Torvalds @ 2005-05-06 16:15 UTC (permalink / raw)
  To: Thomas Glanzmann; +Cc: GIT



On Fri, 6 May 2005, Thomas Glanzmann wrote:
>
> I need a way to lock a repository for certain actions.

Nope - if you want to serialize something, you'll need to write your own 
serialization scripts. git doesn't care, because all the git operations 
should be totally lockless already. There just isn't any reason to lock as 
far as git is concerned, since the objects are immutable.

The only exception is the "index" file, where we don't want concurrect 
index updates. So that is handled by writers creating the new "index.lock" 
file first, and then when they are done, they rename it to "index".

		Linus

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2005-05-06 16:06 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-05-06 12:31 Locking the repository Thomas Glanzmann
2005-05-06 16:15 ` Linus Torvalds

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).