]> source.dussan.org Git - jgit.git/commit
Support atomic push in JGit client 41/61841/2
authorShawn Pearce <spearce@spearce.org>
Thu, 3 Dec 2015 05:47:58 +0000 (21:47 -0800)
committerShawn Pearce <spearce@spearce.org>
Thu, 3 Dec 2015 06:06:06 +0000 (22:06 -0800)
commit3d8e6b1e16092701c31463092e945b8f00886bb7
treed02684d25c4b68bf331ea3c7405df2ad4cac5b86
parentf109af47d07ecc20767f245a384ebd1dc201b6af
Support atomic push in JGit client

This should mirror the behavior of `git push --atomic` where the
client asks the server to apply all-or-nothing. Some JGit servers
already support this based on a custom DFS backend. InMemoryRepository
is extended to support atomic push for unit testing purposes.

Local disk server side support inside of JGit is a more complex animal
due to the excessive amount of file locking required to protect every
reference as a loose reference.

Change-Id: I15083fbe48447678e034afeffb4639572a32f50c
org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/Push.java
org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/AtomicPushTest.java [new file with mode: 0644]
org.eclipse.jgit/resources/org/eclipse/jgit/internal/JGitText.properties
org.eclipse.jgit/src/org/eclipse/jgit/api/PushCommand.java
org.eclipse.jgit/src/org/eclipse/jgit/internal/JGitText.java
org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/InMemoryRepository.java
org.eclipse.jgit/src/org/eclipse/jgit/transport/BasePackPushConnection.java
org.eclipse.jgit/src/org/eclipse/jgit/transport/PushProcess.java
org.eclipse.jgit/src/org/eclipse/jgit/transport/Transport.java