Class RecursiveApprovalCopier
- java.lang.Object
-
- com.google.gerrit.server.approval.RecursiveApprovalCopier
-
public class RecursiveApprovalCopier extends Object
-
-
Constructor Summary
Constructors Constructor Description RecursiveApprovalCopier(BatchUpdate.Factory batchUpdateFactory, GitRepositoryManager repositoryManager, InternalUser.Factory internalUserFactory, ApprovalsUtil approvalsUtil, ChangeNotes.Factory changeNotesFactory, ExecutorService executor)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
persist(Change change)
void
persist(Project.NameKey project, Consumer<Change> labelsCopiedListener)
void
persistStandalone()
This method assumes it is used as a standalone program having exclusive access to the Git repositories.
-
-
-
Constructor Detail
-
RecursiveApprovalCopier
@Inject public RecursiveApprovalCopier(BatchUpdate.Factory batchUpdateFactory, GitRepositoryManager repositoryManager, InternalUser.Factory internalUserFactory, ApprovalsUtil approvalsUtil, ChangeNotes.Factory changeNotesFactory, ExecutorService executor)
-
-
Method Detail
-
persistStandalone
public void persistStandalone() throws org.eclipse.jgit.errors.RepositoryNotFoundException, IOException, InterruptedException, ExecutionException
This method assumes it is used as a standalone program having exclusive access to the Git repositories. Therefore, it will (safely) skip locking of the loose refs when performing batch ref-updates.- Throws:
org.eclipse.jgit.errors.RepositoryNotFoundException
IOException
InterruptedException
ExecutionException
-
persist
public void persist(Project.NameKey project, Consumer<Change> labelsCopiedListener) throws IOException, org.eclipse.jgit.errors.RepositoryNotFoundException, InterruptedException, ExecutionException
- Throws:
IOException
org.eclipse.jgit.errors.RepositoryNotFoundException
InterruptedException
ExecutionException
-
persist
public void persist(Change change) throws UpdateException, RestApiException
- Throws:
UpdateException
RestApiException
-
-