git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v3 0/5] ref-transactions-rename
@ 2014-06-18 17:24 Ronnie Sahlberg
  2014-06-18 17:24 ` [PATCH v3 1/5] refs.c: allow passing raw git_committer_info as email to _update_reflog Ronnie Sahlberg
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: Ronnie Sahlberg @ 2014-06-18 17:24 UTC (permalink / raw)
  To: git; +Cc: mhagger, Ronnie Sahlberg

These patches can also be found at:
https://github.com/rsahlberg/git/tree/ref-transactions-rename
This series is based on, and applies ontop of, the previous
ref-transactions-reflog series, also found at my githup repo.

This series updates the reflog handling and converts rename_ref to use a
single transaction to delete the old ref, create the new ref and to move
the reflog.

In order to make the transaction fully atomic we also introduce support
for using the packed refs file for performing the delete-and-create that
is done during the rename. This means that the rename operation is
fully atomic for all external observers and there is no longer a point in
time where the sha1 is unreferenced, after the old ref has been deleted
but before the new ref has been created.

Additionally, since we now use the transaction API for the reflog changes
we no longer need to disallow renames for refs whose reflogs are symbolic
links.


Version 3:
 - Updated to build ontop of current ref-transactions-reflog


Ronnie Sahlberg (5):
  refs.c: allow passing raw git_committer_info as email to
    _update_reflog
  refs.c: return error instead of dying when locking fails during
    transaction
  refs.c: use packed refs when deleting refs during a transaction
  refs.c: update rename_ref to use a transaction
  refs.c: rollback the lockfile before we die() in repack_without_refs

 builtin/remote.c  |  13 +-
 refs.c            | 368 +++++++++++++++++++++++++++++-------------------------
 refs.h            |   1 +
 t/t3200-branch.sh |   7 --
 4 files changed, 209 insertions(+), 180 deletions(-)

-- 
2.0.0.467.g08c0633

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

end of thread, other threads:[~2014-06-18 17:24 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-06-18 17:24 [PATCH v3 0/5] ref-transactions-rename Ronnie Sahlberg
2014-06-18 17:24 ` [PATCH v3 1/5] refs.c: allow passing raw git_committer_info as email to _update_reflog Ronnie Sahlberg
2014-06-18 17:24 ` [PATCH v3 2/5] refs.c: return error instead of dying when locking fails during transaction Ronnie Sahlberg
2014-06-18 17:24 ` [PATCH v3 3/5] refs.c: use packed refs when deleting refs during a transaction Ronnie Sahlberg
2014-06-18 17:24 ` [PATCH v3 4/5] refs.c: update rename_ref to use " Ronnie Sahlberg
2014-06-18 17:24 ` [PATCH v3 5/5] refs.c: rollback the lockfile before we die() in repack_without_refs Ronnie Sahlberg

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).