Commit 425363a3 authored by Georges Racinet on mutations.racinet.fr's avatar Georges Racinet on mutations.racinet.fr
Browse files

Protocol: updated to GitLab 13.12.2

parent 4c1a09209a71
Pipeline #23176 passed with stages
in 1 minute and 19 seconds
......@@ -25,11 +25,9 @@
// GetLFSPointers retrieves LFS pointers from a given set of object IDs.
// This RPC filters all requested objects and only returns those which refer
// to a valid LFS pointer.
//
// Deprecated in favor of `ListLFSPointers`, passing object IDs as revisions.
rpc GetLFSPointers(GetLFSPointersRequest) returns (stream GetLFSPointersResponse) {
option (op_type) = {
op: ACCESSOR
};
}
......@@ -30,31 +28,9 @@
rpc GetLFSPointers(GetLFSPointersRequest) returns (stream GetLFSPointersResponse) {
option (op_type) = {
op: ACCESSOR
};
}
// GetNewLFSPointers retrieves LFS pointers for a limited subset of the
// commit graph. It will return all LFS pointers which are reachable by the
// provided revision, but not reachable by any of the limiting references.
//
// Deprecated in favor of `ListLFSPointers`. `NotInAll` can be replaced with
// `REVISION` `--not` `--all`, while `NotInRefs` can be replaced with
// `REVISION` `--not` `NotInRevs...`.
rpc GetNewLFSPointers(GetNewLFSPointersRequest) returns (stream GetNewLFSPointersResponse) {
option (op_type) = {
op: ACCESSOR
};
}
// GetAllLFSPointers retrieves all LFS pointers of the given repository.
//
// Deprecated in favor of `ListLFSPointers`, passing `--all` as revision.
rpc GetAllLFSPointers(GetAllLFSPointersRequest) returns (stream GetAllLFSPointersResponse) {
option (op_type) = {
op: ACCESSOR
};
}
// ListLFSPointers retrieves LFS pointers reachable from a given set of
// revisions by doing a graph walk. This includes both normal revisions like
// an object ID or branch, but also the pseudo-revisions "--all" and "--not"
......@@ -67,9 +43,8 @@
};
}
// ListAllLFSPointers retrieves all LFS pointers in the repository. In
// contrast to `GetAllLFSPointers`, this RPC also includes LFS pointers which
// are not reachable by any reference.
// ListAllLFSPointers retrieves all LFS pointers in the repository, including
// those not reachable by any reference.
rpc ListAllLFSPointers(ListAllLFSPointersRequest) returns (stream ListAllLFSPointersResponse) {
option (op_type) = {
op: ACCESSOR
......@@ -158,45 +133,6 @@
repeated LFSPointer lfs_pointers = 1;
}
// GetNewLFSPointersRequest is a request for the GetNewLFSPointers RPC.
message GetNewLFSPointersRequest {
// Repository is the repository for which LFS pointers should be retrieved
// from.
Repository repository = 1[(target_repository)=true];
// Revision is the revision for which to retrieve new LFS pointers.
bytes revision = 2;
// Limit limits the number of LFS pointers returned.
int32 limit = 3;
// NotInAll limits the revision graph to not include any commits which are
// referenced by a git reference. When `not_in_all` is true, `not_in_refs` is
// ignored.
bool not_in_all = 4;
// NotInRefs is a list of references used to limit the revision graph. Any
// commit reachable by any commit in NotInRefs will not be searched for new
// LFS pointers. This is ignored if NotInAll is set to `true`.
repeated bytes not_in_refs = 5;
}
// GetNewLFSPointersResponse is a response for the GetNewLFSPointers RPC.
message GetNewLFSPointersResponse {
// LfsPointers is the list of LFS pointers which were requested.
repeated LFSPointer lfs_pointers = 1;
}
// GetAllLFSPointersRequest is a request for the GetAllLFSPointers RPC.
message GetAllLFSPointersRequest {
// Repository is the repository for which LFS pointers shoul be retrieved
// from.
Repository repository = 1[(target_repository)=true];
reserved 2;
}
// GetAllLFSPointersResponse is a response for the GetAllLFSPointers RPC.
message GetAllLFSPointersResponse {
// LfsPointers is the list of LFS pointers.
repeated LFSPointer lfs_pointers = 1;
}
// ListLFSPointersRequest is a request for the ListLFSPointers RPC.
message ListLFSPointersRequest {
// Repository is the repository for which LFS pointers should be retrieved
......
......@@ -14,6 +14,10 @@
op: ACCESSOR
};
}
// ResolveConflicts tries to resolve a conflicting merge with a set of
// user-provided merge resolutions. If resolving the conflict succeeds, the
// result will be a new merge commit.
rpc ResolveConflicts(stream ResolveConflictsRequest) returns (ResolveConflictsResponse) {
option (op_type) = {
op: MUTATOR
......@@ -47,4 +51,6 @@
repeated ConflictFile files = 1;
}
// ResolveConflictsRequestHeader is the first message that must be sent for
// each ResolveConflicts call.
message ResolveConflictsRequestHeader {
......@@ -50,2 +56,4 @@
message ResolveConflictsRequestHeader {
// Repository is the repository in which conflicts shall be resolved and
// where SourceBranch shall be updated with the resolved conflict.
Repository repository = 1 [(gitaly.target_repository)=true];
......@@ -51,2 +59,3 @@
Repository repository = 1 [(gitaly.target_repository)=true];
// OurCommitOid is the OID of the commit representing the local commit.
string our_commit_oid = 2;
......@@ -52,2 +61,4 @@
string our_commit_oid = 2;
// TargetRepository is the repository from which TheirCommitOid shall be
// retrieved.
Repository target_repository = 3;
......@@ -53,2 +64,4 @@
Repository target_repository = 3;
// TheirCommitOid is the OID of the commit representing the remote commit
// which is to be merged into the local commit.
string their_commit_oid = 4;
......@@ -54,2 +67,3 @@
string their_commit_oid = 4;
// SourceBranch is the branch on which the new commit shall be created.
bytes source_branch = 5;
......@@ -55,2 +69,4 @@
bytes source_branch = 5;
// TargetBranch identifies the branch which will be fetched from
// TargetRepository in case TheirCommitOid does not exist in Repository.
bytes target_branch = 6;
......@@ -56,2 +72,3 @@
bytes target_branch = 6;
// CommitMessage is the message of the newly created merge commit.
bytes commit_message = 7;
......@@ -57,7 +74,9 @@
bytes commit_message = 7;
// User is the user used as author and committer of the newly created merge
// commit.
User user = 8;
// timestamp is the optional timestamp to use for the commit as committer
// date. If it's not set, the current time will be used.
google.protobuf.Timestamp timestamp = 9;
}
......@@ -58,7 +77,8 @@
User user = 8;
// timestamp is the optional timestamp to use for the commit as committer
// date. If it's not set, the current time will be used.
google.protobuf.Timestamp timestamp = 9;
}
// ResolveConflictsRequest is a request for the ResolveConflicts RPC.
message ResolveConflictsRequest {
......@@ -64,2 +84,5 @@
message ResolveConflictsRequest {
// RequestPayload is the payload part of the request. The first message sent
// must always be a ResolveConflictsRequestHeader, whereas all remaining
// requests must be FilesJson requests.
oneof resolve_conflicts_request_payload {
......@@ -65,2 +88,3 @@
oneof resolve_conflicts_request_payload {
// Header is the initial message specifying parameters of the RPC call.
ResolveConflictsRequestHeader header = 1;
......@@ -66,5 +90,6 @@
ResolveConflictsRequestHeader header = 1;
// FilesJson is a JSON-encoded list of conflicts resolutions.
bytes files_json = 2;
}
}
......@@ -67,5 +92,9 @@
bytes files_json = 2;
}
}
// ResolveConflictsResponse is a response of the ResolveConflicts RPC. Conflict
// resolution may have failed even if the RPC has returned OK. The user must
// check ResolutionError to verify whether the merge commit was correctly
// computed or not.
message ResolveConflictsResponse {
......@@ -71,3 +100,5 @@
message ResolveConflictsResponse {
// ResolutionError contains a description of why conflict resolution has
// failed.
string resolution_error = 1;
}
......@@ -40,6 +40,12 @@
scope_level: STORAGE
};
}
// FindRemoteRootRef tries to find the root reference of a remote
// repository. The root reference is the default branch as pointed to by
// the remotes HEAD reference. Returns an InvalidArgument error if the
// specified remote does not exist and a NotFound error in case no HEAD
// branch was found.
rpc FindRemoteRootRef(FindRemoteRootRefRequest) returns (FindRemoteRootRefResponse) {
option (op_type) = {
op: ACCESSOR
......@@ -119,4 +125,5 @@
bool exists = 1;
}
// FindRemoteRootRefRequest represents a request for the FindRemoteRootRef RPC.
message FindRemoteRootRefRequest {
......@@ -122,2 +129,5 @@
message FindRemoteRootRefRequest {
// Repository is the repository in which the request shall be executed in. If
// a remote name is given, then this is the repository in which the remote
// will be looked up.
Repository repository = 1 [(target_repository)=true];
......@@ -123,4 +133,13 @@
Repository repository = 1 [(target_repository)=true];
string remote = 2;
// Remote is the name of the remote of which the root reference shall be
// looked up. The remote must have been created before this call. This
// parameter is deprecated in favor of `RemoteUrl`, see
// https://gitlab.com/gitlab-org/gitaly/-/issues/1773.
string remote = 2 [deprecated=true];
// RemoteUrl specifies the remote repository URL which should be fetched from.
string remote_url = 3;
// HttpAuthorizationHeader is the HTTP header which should be added to the
// request in order to authenticate against the repository.
string http_authorization_header = 4;
}
......@@ -125,3 +144,5 @@
}
// FindRemoteRootRefResponse represents the response for the FindRemoteRootRef
// request.
message FindRemoteRootRefResponse {
......@@ -127,4 +148,5 @@
message FindRemoteRootRefResponse {
// Ref is the name of the remote root reference.
string ref = 1;
}
......
......@@ -34,11 +34,6 @@
op: ACCESSOR
};
}
rpc WikiFindFile(WikiFindFileRequest) returns (stream WikiFindFileResponse) {
option (op_type) = {
op: ACCESSOR
};
}
rpc WikiGetAllPages(WikiGetAllPagesRequest) returns (stream WikiGetAllPagesResponse) {
option (op_type) = {
op: ACCESSOR
......@@ -144,21 +139,6 @@
WikiPage page = 1;
}
message WikiFindFileRequest {
Repository repository = 1 [(target_repository)=true];
bytes name = 2;
// Optional: revision
bytes revision = 3;
}
message WikiFindFileResponse {
// If 'name' is empty, the file was not found.
bytes name = 1;
string mime_type = 2;
bytes raw_data = 3;
bytes path = 4;
}
message WikiGetAllPagesRequest {
Repository repository = 1 [(target_repository)=true];
// Passing 0 means no limit is applied
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment