Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitaly.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPatrick Steinhardt <psteinhardt@gitlab.com>2020-11-18 14:47:59 +0300
committerPatrick Steinhardt <psteinhardt@gitlab.com>2020-11-18 14:47:59 +0300
commitf4648a1a4f0409532de2cc8d8348d5c326fe3d3b (patch)
treeada18999cf45a6d8674d6fcdf6ba991271e0a822
parentceb74a98a167684aebff86f23a7d8ac6ffc8c91c (diff)
parent087700d0521862fea582a221d74d0bcd5a3f634e (diff)
Merge branch 'add_new_diff_stat_rpc' into 'master'
Add new diff stat rpc See merge request gitlab-org/gitaly!2694
-rw-r--r--internal/git/subcommand.go2
-rw-r--r--internal/gitaly/service/diff/find_changed_paths.go155
-rw-r--r--internal/gitaly/service/diff/find_changed_paths_test.go180
-rw-r--r--proto/diff.proto34
-rw-r--r--proto/go/gitalypb/diff.pb.go364
-rw-r--r--ruby/proto/gitaly/diff_pb.rb22
-rw-r--r--ruby/proto/gitaly/diff_services_pb.rb2
7 files changed, 702 insertions, 57 deletions
diff --git a/internal/git/subcommand.go b/internal/git/subcommand.go
index 0a837723b..9f75fdc94 100644
--- a/internal/git/subcommand.go
+++ b/internal/git/subcommand.go
@@ -11,6 +11,7 @@ const (
scMultiPackIndex = "multi-pack-index"
scRepack = "repack"
scDiff = "diff"
+ scDiffTree = "diff-tree"
scPackRefs = "pack-refs"
scMergeBase = "merge-base"
scHashObject = "hash-object"
@@ -35,6 +36,7 @@ var knownReadOnlyCmds = map[string]struct{}{
scRevParse: struct{}{},
scCountObjects: struct{}{},
scDiff: struct{}{},
+ scDiffTree: struct{}{},
scMergeBase: struct{}{},
scShowRef: struct{}{},
scUploadPack: struct{}{},
diff --git a/internal/gitaly/service/diff/find_changed_paths.go b/internal/gitaly/service/diff/find_changed_paths.go
new file mode 100644
index 000000000..8140bcf95
--- /dev/null
+++ b/internal/gitaly/service/diff/find_changed_paths.go
@@ -0,0 +1,155 @@
+package diff
+
+import (
+ "bufio"
+ "context"
+ "fmt"
+ "io"
+ "strings"
+
+ "github.com/golang/protobuf/proto"
+ "gitlab.com/gitlab-org/gitaly/internal/git"
+ "gitlab.com/gitlab-org/gitaly/internal/helper/chunk"
+ "gitlab.com/gitlab-org/gitaly/proto/go/gitalypb"
+ "google.golang.org/grpc/codes"
+ "google.golang.org/grpc/status"
+)
+
+const (
+ numStatDelimiter = 0
+)
+
+func (s *server) FindChangedPaths(in *gitalypb.FindChangedPathsRequest, stream gitalypb.DiffService_FindChangedPathsServer) error {
+ if err := s.validateFindChangedPathsRequestParams(stream.Context(), in); err != nil {
+ return err
+ }
+
+ diffChunker := chunk.New(&findChangedPathsSender{stream: stream})
+
+ cmd, err := git.SafeCmd(stream.Context(), in.Repository, nil, git.SubCmd{
+ Name: "diff-tree",
+ Flags: []git.Option{
+ git.Flag{Name: "-z"},
+ git.Flag{Name: "--stdin"},
+ git.Flag{Name: "-m"},
+ git.Flag{Name: "-r"},
+ git.Flag{Name: "--name-status"},
+ git.Flag{Name: "--no-renames"},
+ git.Flag{Name: "--no-commit-id"},
+ git.Flag{Name: "--diff-filter=AMDTC"},
+ },
+ }, git.WithStdin(strings.NewReader(strings.Join(in.GetCommits(), "\n")+"\n")))
+ if err != nil {
+ if _, ok := status.FromError(err); ok {
+ return fmt.Errorf("FindChangedPaths Stdin Err: %w", err)
+ }
+ return status.Errorf(codes.Internal, "FindChangedPaths: Cmd Err: %v", err)
+ }
+
+ if err := parsePaths(bufio.NewReader(cmd), diffChunker); err != nil {
+ return fmt.Errorf("FindChangedPaths Parsing Err: %w", err)
+ }
+
+ if err := cmd.Wait(); err != nil {
+ return status.Errorf(codes.Unavailable, "FindChangedPaths: Cmd Wait Err: %v", err)
+ }
+
+ return diffChunker.Flush()
+}
+
+func parsePaths(reader *bufio.Reader, chunker *chunk.Chunker) error {
+ for {
+ path, err := nextPath(reader)
+ if err != nil {
+ if err == io.EOF {
+ break
+ }
+
+ return fmt.Errorf("FindChangedPaths Next Path Err: %w", err)
+ }
+
+ if err := chunker.Send(path); err != nil {
+ return fmt.Errorf("FindChangedPaths: err sending to chunker: %v", err)
+ }
+ }
+
+ return nil
+}
+
+func nextPath(reader *bufio.Reader) (*gitalypb.ChangedPaths, error) {
+ pathStatus, err := reader.ReadBytes(numStatDelimiter)
+ if err != nil {
+ return nil, err
+ }
+
+ path, err := reader.ReadBytes(numStatDelimiter)
+ if err != nil {
+ return nil, err
+ }
+
+ statusTypeMap := map[string]gitalypb.ChangedPaths_Status{
+ "M": gitalypb.ChangedPaths_MODIFIED,
+ "D": gitalypb.ChangedPaths_DELETED,
+ "T": gitalypb.ChangedPaths_TYPE_CHANGE,
+ "C": gitalypb.ChangedPaths_COPIED,
+ "A": gitalypb.ChangedPaths_ADDED,
+ }
+
+ parsedPath, ok := statusTypeMap[string(pathStatus[:len(pathStatus)-1])]
+ if !ok {
+ return nil, status.Errorf(codes.Internal, "FindChangedPaths: Unknown changed paths returned: %v", string(pathStatus))
+ }
+
+ changedPath := &gitalypb.ChangedPaths{
+ Status: parsedPath,
+ Path: path[:len(path)-1],
+ }
+
+ return changedPath, nil
+}
+
+// This sender implements the interface in the chunker class
+type findChangedPathsSender struct {
+ paths []*gitalypb.ChangedPaths
+ stream gitalypb.DiffService_FindChangedPathsServer
+}
+
+func (t *findChangedPathsSender) Reset() {
+ t.paths = nil
+}
+
+func (t *findChangedPathsSender) Append(m proto.Message) {
+ t.paths = append(t.paths, m.(*gitalypb.ChangedPaths))
+}
+
+func (t *findChangedPathsSender) Send() error {
+ return t.stream.Send(&gitalypb.FindChangedPathsResponse{
+ Paths: t.paths,
+ })
+}
+
+func (s *server) validateFindChangedPathsRequestParams(ctx context.Context, in *gitalypb.FindChangedPathsRequest) error {
+ repo := in.GetRepository()
+ if _, err := s.locator.GetRepoPath(repo); err != nil {
+ return err
+ }
+
+ gitRepo := git.NewRepository(repo)
+
+ for _, commit := range in.GetCommits() {
+ if commit == "" {
+ return status.Errorf(codes.InvalidArgument, "FindChangedPaths: commits cannot contain an empty commit")
+ }
+
+ containsRef, err := gitRepo.ContainsRef(ctx, commit+"^{commit}")
+ if err != nil {
+ return fmt.Errorf("contains ref err: %w", err)
+ }
+
+ if !containsRef {
+ return status.Errorf(codes.NotFound, "FindChangedPaths: commit: %v can not be found", commit)
+ }
+ }
+
+ return nil
+}
diff --git a/internal/gitaly/service/diff/find_changed_paths_test.go b/internal/gitaly/service/diff/find_changed_paths_test.go
new file mode 100644
index 000000000..06a47c5f4
--- /dev/null
+++ b/internal/gitaly/service/diff/find_changed_paths_test.go
@@ -0,0 +1,180 @@
+package diff
+
+import (
+ "io"
+ "path/filepath"
+ "testing"
+
+ "github.com/stretchr/testify/require"
+ "gitlab.com/gitlab-org/gitaly/internal/testhelper"
+ "gitlab.com/gitlab-org/gitaly/proto/go/gitalypb"
+ "google.golang.org/grpc/codes"
+ "google.golang.org/grpc/status"
+)
+
+func TestFindChangedPathsRequest_success(t *testing.T) {
+ server, serverSocketPath := runDiffServer(t)
+ defer server.Stop()
+
+ client, conn := newDiffClient(t, serverSocketPath)
+ defer conn.Close()
+
+ testRepo, _, cleanupFn := testhelper.NewTestRepo(t)
+ defer cleanupFn()
+
+ ctx, cancel := testhelper.Context()
+ defer cancel()
+
+ testCases := []struct {
+ desc string
+ commits []string
+ expectedPaths []*gitalypb.ChangedPaths
+ }{
+ {
+ "Returns the expected results without a merge commit",
+ []string{"e4003da16c1c2c3fc4567700121b17bf8e591c6c", "57290e673a4c87f51294f5216672cbc58d485d25", "8a0f2ee90d940bfb0ba1e14e8214b0649056e4ab", "d59c60028b053793cecfb4022de34602e1a9218e"},
+ []*gitalypb.ChangedPaths{
+ {
+ Status: gitalypb.ChangedPaths_MODIFIED,
+ Path: []byte("CONTRIBUTING.md"),
+ },
+ {
+ Status: gitalypb.ChangedPaths_MODIFIED,
+ Path: []byte("MAINTENANCE.md"),
+ },
+ {
+ Status: gitalypb.ChangedPaths_ADDED,
+ Path: []byte("gitaly/ใƒ†ใ‚นใƒˆ.txt"),
+ },
+ {
+ Status: gitalypb.ChangedPaths_ADDED,
+ Path: []byte("gitaly/deleted-file"),
+ },
+ {
+ Status: gitalypb.ChangedPaths_ADDED,
+ Path: []byte("gitaly/file-with-multiple-chunks"),
+ },
+ {
+ Status: gitalypb.ChangedPaths_ADDED,
+ Path: []byte("gitaly/mode-file"),
+ },
+ {
+ Status: gitalypb.ChangedPaths_ADDED,
+ Path: []byte("gitaly/mode-file-with-mods"),
+ },
+ {
+ Status: gitalypb.ChangedPaths_ADDED,
+ Path: []byte("gitaly/named-file"),
+ },
+ {
+ Status: gitalypb.ChangedPaths_ADDED,
+ Path: []byte("gitaly/named-file-with-mods"),
+ },
+ {
+ Status: gitalypb.ChangedPaths_DELETED,
+ Path: []byte("files/js/commit.js.coffee"),
+ },
+ },
+ },
+ {
+ "Returns the expected results with a merge commit",
+ []string{"7975be0116940bf2ad4321f79d02a55c5f7779aa", "55bc176024cfa3baaceb71db584c7e5df900ea65"},
+ []*gitalypb.ChangedPaths{
+ {
+ Status: gitalypb.ChangedPaths_ADDED,
+ Path: []byte("files/images/emoji.png"),
+ },
+ {
+ Status: gitalypb.ChangedPaths_MODIFIED,
+ Path: []byte(".gitattributes"),
+ },
+ },
+ },
+ }
+
+ for _, tc := range testCases {
+ t.Run(tc.desc, func(t *testing.T) {
+ rpcRequest := &gitalypb.FindChangedPathsRequest{Repository: testRepo, Commits: tc.commits}
+
+ stream, err := client.FindChangedPaths(ctx, rpcRequest)
+ require.NoError(t, err)
+
+ var paths []*gitalypb.ChangedPaths
+ for {
+ fetchedPaths, err := stream.Recv()
+ if err == io.EOF {
+ break
+ }
+
+ require.NoError(t, err)
+
+ paths = append(paths, fetchedPaths.GetPaths()...)
+ }
+
+ require.Equal(t, tc.expectedPaths, paths)
+ })
+ }
+}
+
+func TestFindChangedPathsRequest_failing(t *testing.T) {
+ server, serverSocketPath := runDiffServer(t)
+ defer server.Stop()
+
+ client, conn := newDiffClient(t, serverSocketPath)
+ defer conn.Close()
+
+ ctx, cancel := testhelper.Context()
+ defer cancel()
+
+ testRepo, _, cleanupFn := testhelper.NewTestRepo(t)
+ defer cleanupFn()
+
+ tests := []struct {
+ desc string
+ repo *gitalypb.Repository
+ commits []string
+ err error
+ }{
+ {
+ desc: "Repo not found",
+ repo: &gitalypb.Repository{StorageName: testRepo.GetStorageName(), RelativePath: "bar.git"},
+ commits: []string{"e4003da16c1c2c3fc4567700121b17bf8e591c6c", "8a0f2ee90d940bfb0ba1e14e8214b0649056e4ab"},
+ err: status.Errorf(codes.NotFound, "GetRepoPath: not a git repository: %q", filepath.Join(testhelper.GitlabTestStoragePath(), "bar.git")),
+ },
+ {
+ desc: "Storage not found",
+ repo: &gitalypb.Repository{StorageName: "foo", RelativePath: "bar.git"},
+ commits: []string{"e4003da16c1c2c3fc4567700121b17bf8e591c6c", "8a0f2ee90d940bfb0ba1e14e8214b0649056e4ab"},
+ err: status.Error(codes.InvalidArgument, "GetStorageByName: no such storage: \"foo\""),
+ },
+ {
+ desc: "Commits cannot contain an empty commit",
+ repo: testRepo,
+ commits: []string{""},
+ err: status.Error(codes.InvalidArgument, "FindChangedPaths: commits cannot contain an empty commit"),
+ },
+ {
+ desc: "Invalid commit",
+ repo: testRepo,
+ commits: []string{"invalidinvalidinvalid", "8a0f2ee90d940bfb0ba1e14e8214b0649056e4ab"},
+ err: status.Error(codes.NotFound, "FindChangedPaths: commit: invalidinvalidinvalid can not be found"),
+ },
+ {
+ desc: "Commit not found",
+ repo: testRepo,
+ commits: []string{"z4003da16c1c2c3fc4567700121b17bf8e591c6c", "8a0f2ee90d940bfb0ba1e14e8214b0649056e4ab"},
+ err: status.Error(codes.NotFound, "FindChangedPaths: commit: z4003da16c1c2c3fc4567700121b17bf8e591c6c can not be found"),
+ },
+ }
+
+ for _, tc := range tests {
+ rpcRequest := &gitalypb.FindChangedPathsRequest{Repository: tc.repo, Commits: tc.commits}
+ stream, err := client.FindChangedPaths(ctx, rpcRequest)
+ require.NoError(t, err)
+
+ t.Run(tc.desc, func(t *testing.T) {
+ _, err := stream.Recv()
+ require.Equal(t, tc.err, err)
+ })
+ }
+}
diff --git a/proto/diff.proto b/proto/diff.proto
index 24b728edc..b7199fb23 100644
--- a/proto/diff.proto
+++ b/proto/diff.proto
@@ -35,6 +35,12 @@ service DiffService {
op: ACCESSOR
};
}
+ // Return a list of files changed along with the status of each file
+ rpc FindChangedPaths(FindChangedPathsRequest) returns (stream FindChangedPathsResponse) {
+ option (op_type) = {
+ op: ACCESSOR
+ };
+ }
}
message CommitDiffRequest {
@@ -143,3 +149,31 @@ message DiffStats {
message DiffStatsResponse {
repeated DiffStats stats = 1;
}
+
+// Given a list of commits, return the files changed. Each commit is compared
+// to its parent. Merge commits will show files which are different to all of
+// its parents.
+message FindChangedPathsRequest {
+ Repository repository = 1 [(target_repository)=true];
+ repeated string commits = 2;
+}
+
+// Returns a list of files that have been changed in the commits given
+message FindChangedPathsResponse {
+ repeated ChangedPaths paths = 1;
+}
+
+// Includes the path of the file, and the status of the change
+message ChangedPaths {
+ enum Status {
+ ADDED = 0;
+ MODIFIED = 1;
+ DELETED = 2;
+ TYPE_CHANGE = 3;
+ COPIED = 4;
+ }
+
+ bytes path = 1;
+ Status status = 2;
+}
+
diff --git a/proto/go/gitalypb/diff.pb.go b/proto/go/gitalypb/diff.pb.go
index f7590c051..0b0d0f294 100644
--- a/proto/go/gitalypb/diff.pb.go
+++ b/proto/go/gitalypb/diff.pb.go
@@ -24,6 +24,40 @@ var _ = math.Inf
// proto package needs to be updated.
const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package
+type ChangedPaths_Status int32
+
+const (
+ ChangedPaths_ADDED ChangedPaths_Status = 0
+ ChangedPaths_MODIFIED ChangedPaths_Status = 1
+ ChangedPaths_DELETED ChangedPaths_Status = 2
+ ChangedPaths_TYPE_CHANGE ChangedPaths_Status = 3
+ ChangedPaths_COPIED ChangedPaths_Status = 4
+)
+
+var ChangedPaths_Status_name = map[int32]string{
+ 0: "ADDED",
+ 1: "MODIFIED",
+ 2: "DELETED",
+ 3: "TYPE_CHANGE",
+ 4: "COPIED",
+}
+
+var ChangedPaths_Status_value = map[string]int32{
+ "ADDED": 0,
+ "MODIFIED": 1,
+ "DELETED": 2,
+ "TYPE_CHANGE": 3,
+ "COPIED": 4,
+}
+
+func (x ChangedPaths_Status) String() string {
+ return proto.EnumName(ChangedPaths_Status_name, int32(x))
+}
+
+func (ChangedPaths_Status) EnumDescriptor() ([]byte, []int) {
+ return fileDescriptor_686521effc814b25, []int{14, 0}
+}
+
type CommitDiffRequest struct {
Repository *Repository `protobuf:"bytes,1,opt,name=repository,proto3" json:"repository,omitempty"`
LeftCommitId string `protobuf:"bytes,2,opt,name=left_commit_id,json=leftCommitId,proto3" json:"left_commit_id,omitempty"`
@@ -834,7 +868,146 @@ func (m *DiffStatsResponse) GetStats() []*DiffStats {
return nil
}
+// Given a list of commits, return the files changed. Each commit is compared
+// to its parent. Merge commits will show files which are different to all of
+// its parents.
+type FindChangedPathsRequest struct {
+ Repository *Repository `protobuf:"bytes,1,opt,name=repository,proto3" json:"repository,omitempty"`
+ Commits []string `protobuf:"bytes,2,rep,name=commits,proto3" json:"commits,omitempty"`
+ XXX_NoUnkeyedLiteral struct{} `json:"-"`
+ XXX_unrecognized []byte `json:"-"`
+ XXX_sizecache int32 `json:"-"`
+}
+
+func (m *FindChangedPathsRequest) Reset() { *m = FindChangedPathsRequest{} }
+func (m *FindChangedPathsRequest) String() string { return proto.CompactTextString(m) }
+func (*FindChangedPathsRequest) ProtoMessage() {}
+func (*FindChangedPathsRequest) Descriptor() ([]byte, []int) {
+ return fileDescriptor_686521effc814b25, []int{12}
+}
+
+func (m *FindChangedPathsRequest) XXX_Unmarshal(b []byte) error {
+ return xxx_messageInfo_FindChangedPathsRequest.Unmarshal(m, b)
+}
+func (m *FindChangedPathsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ return xxx_messageInfo_FindChangedPathsRequest.Marshal(b, m, deterministic)
+}
+func (m *FindChangedPathsRequest) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_FindChangedPathsRequest.Merge(m, src)
+}
+func (m *FindChangedPathsRequest) XXX_Size() int {
+ return xxx_messageInfo_FindChangedPathsRequest.Size(m)
+}
+func (m *FindChangedPathsRequest) XXX_DiscardUnknown() {
+ xxx_messageInfo_FindChangedPathsRequest.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_FindChangedPathsRequest proto.InternalMessageInfo
+
+func (m *FindChangedPathsRequest) GetRepository() *Repository {
+ if m != nil {
+ return m.Repository
+ }
+ return nil
+}
+
+func (m *FindChangedPathsRequest) GetCommits() []string {
+ if m != nil {
+ return m.Commits
+ }
+ return nil
+}
+
+// Returns a list of files that have been changed in the commits given
+type FindChangedPathsResponse struct {
+ Paths []*ChangedPaths `protobuf:"bytes,1,rep,name=paths,proto3" json:"paths,omitempty"`
+ XXX_NoUnkeyedLiteral struct{} `json:"-"`
+ XXX_unrecognized []byte `json:"-"`
+ XXX_sizecache int32 `json:"-"`
+}
+
+func (m *FindChangedPathsResponse) Reset() { *m = FindChangedPathsResponse{} }
+func (m *FindChangedPathsResponse) String() string { return proto.CompactTextString(m) }
+func (*FindChangedPathsResponse) ProtoMessage() {}
+func (*FindChangedPathsResponse) Descriptor() ([]byte, []int) {
+ return fileDescriptor_686521effc814b25, []int{13}
+}
+
+func (m *FindChangedPathsResponse) XXX_Unmarshal(b []byte) error {
+ return xxx_messageInfo_FindChangedPathsResponse.Unmarshal(m, b)
+}
+func (m *FindChangedPathsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ return xxx_messageInfo_FindChangedPathsResponse.Marshal(b, m, deterministic)
+}
+func (m *FindChangedPathsResponse) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_FindChangedPathsResponse.Merge(m, src)
+}
+func (m *FindChangedPathsResponse) XXX_Size() int {
+ return xxx_messageInfo_FindChangedPathsResponse.Size(m)
+}
+func (m *FindChangedPathsResponse) XXX_DiscardUnknown() {
+ xxx_messageInfo_FindChangedPathsResponse.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_FindChangedPathsResponse proto.InternalMessageInfo
+
+func (m *FindChangedPathsResponse) GetPaths() []*ChangedPaths {
+ if m != nil {
+ return m.Paths
+ }
+ return nil
+}
+
+// Includes the path of the file, and the status of the change
+type ChangedPaths struct {
+ Path []byte `protobuf:"bytes,1,opt,name=path,proto3" json:"path,omitempty"`
+ Status ChangedPaths_Status `protobuf:"varint,2,opt,name=status,proto3,enum=gitaly.ChangedPaths_Status" json:"status,omitempty"`
+ XXX_NoUnkeyedLiteral struct{} `json:"-"`
+ XXX_unrecognized []byte `json:"-"`
+ XXX_sizecache int32 `json:"-"`
+}
+
+func (m *ChangedPaths) Reset() { *m = ChangedPaths{} }
+func (m *ChangedPaths) String() string { return proto.CompactTextString(m) }
+func (*ChangedPaths) ProtoMessage() {}
+func (*ChangedPaths) Descriptor() ([]byte, []int) {
+ return fileDescriptor_686521effc814b25, []int{14}
+}
+
+func (m *ChangedPaths) XXX_Unmarshal(b []byte) error {
+ return xxx_messageInfo_ChangedPaths.Unmarshal(m, b)
+}
+func (m *ChangedPaths) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
+ return xxx_messageInfo_ChangedPaths.Marshal(b, m, deterministic)
+}
+func (m *ChangedPaths) XXX_Merge(src proto.Message) {
+ xxx_messageInfo_ChangedPaths.Merge(m, src)
+}
+func (m *ChangedPaths) XXX_Size() int {
+ return xxx_messageInfo_ChangedPaths.Size(m)
+}
+func (m *ChangedPaths) XXX_DiscardUnknown() {
+ xxx_messageInfo_ChangedPaths.DiscardUnknown(m)
+}
+
+var xxx_messageInfo_ChangedPaths proto.InternalMessageInfo
+
+func (m *ChangedPaths) GetPath() []byte {
+ if m != nil {
+ return m.Path
+ }
+ return nil
+}
+
+func (m *ChangedPaths) GetStatus() ChangedPaths_Status {
+ if m != nil {
+ return m.Status
+ }
+ return ChangedPaths_ADDED
+}
+
func init() {
+ proto.RegisterEnum("gitaly.ChangedPaths_Status", ChangedPaths_Status_name, ChangedPaths_Status_value)
proto.RegisterType((*CommitDiffRequest)(nil), "gitaly.CommitDiffRequest")
proto.RegisterType((*CommitDiffResponse)(nil), "gitaly.CommitDiffResponse")
proto.RegisterType((*CommitDeltaRequest)(nil), "gitaly.CommitDeltaRequest")
@@ -847,68 +1020,80 @@ func init() {
proto.RegisterType((*DiffStatsRequest)(nil), "gitaly.DiffStatsRequest")
proto.RegisterType((*DiffStats)(nil), "gitaly.DiffStats")
proto.RegisterType((*DiffStatsResponse)(nil), "gitaly.DiffStatsResponse")
+ proto.RegisterType((*FindChangedPathsRequest)(nil), "gitaly.FindChangedPathsRequest")
+ proto.RegisterType((*FindChangedPathsResponse)(nil), "gitaly.FindChangedPathsResponse")
+ proto.RegisterType((*ChangedPaths)(nil), "gitaly.ChangedPaths")
}
func init() { proto.RegisterFile("diff.proto", fileDescriptor_686521effc814b25) }
var fileDescriptor_686521effc814b25 = []byte{
- // 882 bytes of a gzipped FileDescriptorProto
- 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xcc, 0x56, 0xcd, 0x6e, 0xe3, 0x36,
- 0x10, 0x86, 0x6c, 0x59, 0x91, 0xc7, 0x8a, 0x93, 0x30, 0x45, 0x56, 0xf1, 0xf6, 0x60, 0x08, 0xfb,
- 0x63, 0xa0, 0x6d, 0xb2, 0x48, 0x2f, 0x7b, 0xe8, 0x29, 0x1b, 0xb4, 0xc8, 0x22, 0x41, 0x03, 0xf5,
- 0x50, 0xa0, 0x17, 0x81, 0x36, 0x29, 0x9b, 0xa8, 0x24, 0xba, 0x22, 0x1b, 0x27, 0x8f, 0xd0, 0x27,
- 0xe8, 0xb6, 0x2f, 0x50, 0xa0, 0xc7, 0x3e, 0x44, 0x9f, 0xa9, 0xe8, 0xa9, 0xe0, 0x50, 0x92, 0xe5,
- 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, 0x60, 0x06, 0x3a, 0xdd, 0x0f, 0x0b, 0xee,
+ 0x1f, 0x70, 0xfe, 0xec, 0x7b, 0x2e, 0x0e, 0xf1, 0xa4, 0x3f, 0xa5, 0xd1, 0xa9, 0xfc, 0xfc, 0x82,
+ 0x26, 0xb3, 0x53, 0x99, 0xe2, 0x54, 0xfc, 0x53, 0x7e, 0x3a, 0xa3, 0x59, 0xbc, 0x98, 0x4c, 0x34,
+ 0x01, 0x3d, 0xff, 0x37, 0x00, 0x00, 0xff, 0xff, 0x0b, 0xb2, 0x24, 0xdd, 0xd7, 0x0b, 0x00, 0x00,
}
// Reference imports to suppress errors if they are not otherwise used.
@@ -930,6 +1115,8 @@ type DiffServiceClient interface {
RawDiff(ctx context.Context, in *RawDiffRequest, opts ...grpc.CallOption) (DiffService_RawDiffClient, error)
RawPatch(ctx context.Context, in *RawPatchRequest, opts ...grpc.CallOption) (DiffService_RawPatchClient, error)
DiffStats(ctx context.Context, in *DiffStatsRequest, opts ...grpc.CallOption) (DiffService_DiffStatsClient, error)
+ // Return a list of files changed along with the status of each file
+ FindChangedPaths(ctx context.Context, in *FindChangedPathsRequest, opts ...grpc.CallOption) (DiffService_FindChangedPathsClient, error)
}
type diffServiceClient struct {
@@ -1100,6 +1287,38 @@ func (x *diffServiceDiffStatsClient) Recv() (*DiffStatsResponse, error) {
return m, nil
}
+func (c *diffServiceClient) FindChangedPaths(ctx context.Context, in *FindChangedPathsRequest, opts ...grpc.CallOption) (DiffService_FindChangedPathsClient, error) {
+ stream, err := c.cc.NewStream(ctx, &_DiffService_serviceDesc.Streams[5], "/gitaly.DiffService/FindChangedPaths", opts...)
+ if err != nil {
+ return nil, err
+ }
+ x := &diffServiceFindChangedPathsClient{stream}
+ if err := x.ClientStream.SendMsg(in); err != nil {
+ return nil, err
+ }
+ if err := x.ClientStream.CloseSend(); err != nil {
+ return nil, err
+ }
+ return x, nil
+}
+
+type DiffService_FindChangedPathsClient interface {
+ Recv() (*FindChangedPathsResponse, error)
+ grpc.ClientStream
+}
+
+type diffServiceFindChangedPathsClient struct {
+ grpc.ClientStream
+}
+
+func (x *diffServiceFindChangedPathsClient) Recv() (*FindChangedPathsResponse, error) {
+ m := new(FindChangedPathsResponse)
+ if err := x.ClientStream.RecvMsg(m); err != nil {
+ return nil, err
+ }
+ return m, nil
+}
+
// DiffServiceServer is the server API for DiffService service.
type DiffServiceServer interface {
// Returns stream of CommitDiffResponse with patches chunked over messages
@@ -1109,6 +1328,8 @@ type DiffServiceServer interface {
RawDiff(*RawDiffRequest, DiffService_RawDiffServer) error
RawPatch(*RawPatchRequest, DiffService_RawPatchServer) error
DiffStats(*DiffStatsRequest, DiffService_DiffStatsServer) error
+ // Return a list of files changed along with the status of each file
+ FindChangedPaths(*FindChangedPathsRequest, DiffService_FindChangedPathsServer) error
}
// UnimplementedDiffServiceServer can be embedded to have forward compatible implementations.
@@ -1130,6 +1351,9 @@ func (*UnimplementedDiffServiceServer) RawPatch(req *RawPatchRequest, srv DiffSe
func (*UnimplementedDiffServiceServer) DiffStats(req *DiffStatsRequest, srv DiffService_DiffStatsServer) error {
return status.Errorf(codes.Unimplemented, "method DiffStats not implemented")
}
+func (*UnimplementedDiffServiceServer) FindChangedPaths(req *FindChangedPathsRequest, srv DiffService_FindChangedPathsServer) error {
+ return status.Errorf(codes.Unimplemented, "method FindChangedPaths not implemented")
+}
func RegisterDiffServiceServer(s *grpc.Server, srv DiffServiceServer) {
s.RegisterService(&_DiffService_serviceDesc, srv)
@@ -1240,6 +1464,27 @@ func (x *diffServiceDiffStatsServer) Send(m *DiffStatsResponse) error {
return x.ServerStream.SendMsg(m)
}
+func _DiffService_FindChangedPaths_Handler(srv interface{}, stream grpc.ServerStream) error {
+ m := new(FindChangedPathsRequest)
+ if err := stream.RecvMsg(m); err != nil {
+ return err
+ }
+ return srv.(DiffServiceServer).FindChangedPaths(m, &diffServiceFindChangedPathsServer{stream})
+}
+
+type DiffService_FindChangedPathsServer interface {
+ Send(*FindChangedPathsResponse) error
+ grpc.ServerStream
+}
+
+type diffServiceFindChangedPathsServer struct {
+ grpc.ServerStream
+}
+
+func (x *diffServiceFindChangedPathsServer) Send(m *FindChangedPathsResponse) error {
+ return x.ServerStream.SendMsg(m)
+}
+
var _DiffService_serviceDesc = grpc.ServiceDesc{
ServiceName: "gitaly.DiffService",
HandlerType: (*DiffServiceServer)(nil),
@@ -1270,6 +1515,11 @@ var _DiffService_serviceDesc = grpc.ServiceDesc{
Handler: _DiffService_DiffStats_Handler,
ServerStreams: true,
},
+ {
+ StreamName: "FindChangedPaths",
+ Handler: _DiffService_FindChangedPaths_Handler,
+ ServerStreams: true,
+ },
},
Metadata: "diff.proto",
}
diff --git a/ruby/proto/gitaly/diff_pb.rb b/ruby/proto/gitaly/diff_pb.rb
index 3afb4c190..8baa2817f 100644
--- a/ruby/proto/gitaly/diff_pb.rb
+++ b/ruby/proto/gitaly/diff_pb.rb
@@ -84,6 +84,24 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
add_message "gitaly.DiffStatsResponse" do
repeated :stats, :message, 1, "gitaly.DiffStats"
end
+ add_message "gitaly.FindChangedPathsRequest" do
+ optional :repository, :message, 1, "gitaly.Repository"
+ repeated :commits, :string, 2
+ end
+ add_message "gitaly.FindChangedPathsResponse" do
+ repeated :paths, :message, 1, "gitaly.ChangedPaths"
+ end
+ add_message "gitaly.ChangedPaths" do
+ optional :path, :bytes, 1
+ optional :status, :enum, 2, "gitaly.ChangedPaths.Status"
+ end
+ add_enum "gitaly.ChangedPaths.Status" do
+ value :ADDED, 0
+ value :MODIFIED, 1
+ value :DELETED, 2
+ value :TYPE_CHANGE, 3
+ value :COPIED, 4
+ end
end
end
@@ -100,4 +118,8 @@ module Gitaly
DiffStatsRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("gitaly.DiffStatsRequest").msgclass
DiffStats = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("gitaly.DiffStats").msgclass
DiffStatsResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("gitaly.DiffStatsResponse").msgclass
+ FindChangedPathsRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("gitaly.FindChangedPathsRequest").msgclass
+ FindChangedPathsResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("gitaly.FindChangedPathsResponse").msgclass
+ ChangedPaths = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("gitaly.ChangedPaths").msgclass
+ ChangedPaths::Status = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("gitaly.ChangedPaths.Status").enummodule
end
diff --git a/ruby/proto/gitaly/diff_services_pb.rb b/ruby/proto/gitaly/diff_services_pb.rb
index e2e34621d..27fe976e2 100644
--- a/ruby/proto/gitaly/diff_services_pb.rb
+++ b/ruby/proto/gitaly/diff_services_pb.rb
@@ -21,6 +21,8 @@ module Gitaly
rpc :RawDiff, Gitaly::RawDiffRequest, stream(Gitaly::RawDiffResponse)
rpc :RawPatch, Gitaly::RawPatchRequest, stream(Gitaly::RawPatchResponse)
rpc :DiffStats, Gitaly::DiffStatsRequest, stream(Gitaly::DiffStatsResponse)
+ # Return a list of files changed along with the status of each file
+ rpc :FindChangedPaths, Gitaly::FindChangedPathsRequest, stream(Gitaly::FindChangedPathsResponse)
end
Stub = Service.rpc_stub_class