Package com.google.gerrit.server.submit
Class MergeOpRepoManager
- java.lang.Object
-
- com.google.gerrit.server.submit.MergeOpRepoManager
-
- All Implemented Interfaces:
AutoCloseable
public class MergeOpRepoManager extends Object implements AutoCloseable
This is a helper class for MergeOp and not intended for general use.Some database backends require to open a repository just once within a transaction of a submission, this caches open repositories to satisfy that requirement.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
MergeOpRepoManager.OpenBranch
class
MergeOpRepoManager.OpenRepo
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description List<BatchUpdate>
batchUpdates(Collection<Project.NameKey> projects)
void
close()
MergeOpRepoManager.OpenRepo
getRepo(Project.NameKey project)
void
resetUpdates(com.google.common.collect.ImmutableSet<Project.NameKey> projects)
void
setContext(Timestamp ts, IdentifiedUser caller, NotifyResolver.Result notify)
-
-
-
Method Detail
-
setContext
public void setContext(Timestamp ts, IdentifiedUser caller, NotifyResolver.Result notify)
-
getRepo
public MergeOpRepoManager.OpenRepo getRepo(Project.NameKey project) throws NoSuchProjectException, IOException
- Throws:
NoSuchProjectException
IOException
-
batchUpdates
public List<BatchUpdate> batchUpdates(Collection<Project.NameKey> projects) throws NoSuchProjectException, IOException
- Throws:
NoSuchProjectException
IOException
-
resetUpdates
public void resetUpdates(com.google.common.collect.ImmutableSet<Project.NameKey> projects) throws NoSuchProjectException, IOException
- Throws:
NoSuchProjectException
IOException
-
close
public void close()
- Specified by:
close
in interfaceAutoCloseable
-
-