...
 
Commits (3)
  • Zeger-Jan van de Weg's avatar
    Allow git.Command to receive an GitRepo interface · 785b62fb
    Zeger-Jan van de Weg authored
    For other types of repositories, which do use the git binary, it might
    be convenient if the git.Command function accepts an interface type, not
    an concrete type.
    
    This is useful when ObjectPools would like to leverage the
    infrastructure which is tried and tested.
    
    Object Pools:
    - gitlab-org&189
    785b62fb
  • Zeger-Jan van de Weg's avatar
    Introduce a security func to scrub error messages · e405b94d
    Zeger-Jan van de Weg authored
    This helper was around already, so this is a duplication but now its
    tested. Later we could move all other occurances to leverage this
    helper.
    e405b94d
  • Zeger-Jan van de Weg's avatar
    Introduce Create, and Remove ObjectPool RPC · 2615d15d
    Zeger-Jan van de Weg authored
    For object pools the creation and removal will be dictated by
    gitlab-rails, which will do so by making requesting a RPC.
    
    Create will clone a repository to the object pools path, and remove the
    origin remote. Also, the local refs are deleted. This does not remove
    the objects, which can be reused when linking the repository in a later
    RPC reqeust.
    
    The implementation depends on the proto which is yet to be merged, and
    is not set yet.
    
    Closes gitlab-org/gitaly#1344
    2615d15d
......@@ -5,14 +5,14 @@ import (
"path"
"strings"
"gitlab.com/gitlab-org/gitaly-proto/go/gitalypb"
"gitlab.com/gitlab-org/gitaly/internal/git/repository"
"gitlab.com/gitlab-org/gitaly/internal/helper"
)
// PathAndEnv finds the disk path to a repository, and returns the
// alternate object directory environment variables encoded in the
// gitalypb.Repository instance.
func PathAndEnv(repo *gitalypb.Repository) (string, []string, error) {
func PathAndEnv(repo repository.GitRepo) (string, []string, error) {
repoPath, err := helper.GetRepoPath(repo)
if err != nil {
return "", nil, err
......
......@@ -5,15 +5,14 @@ import (
"io"
"os/exec"
"gitlab.com/gitlab-org/gitaly-proto/go/gitalypb"
"gitlab.com/gitlab-org/gitaly/internal/command"
"gitlab.com/gitlab-org/gitaly/internal/git/alternates"
"gitlab.com/gitlab-org/gitaly/internal/git/repository"
)
// Command creates a git.Command with the given args and Repository
func Command(ctx context.Context, repo *gitalypb.Repository, args ...string) (*command.Command, error) {
func Command(ctx context.Context, repo repository.GitRepo, args ...string) (*command.Command, error) {
repoPath, env, err := alternates.PathAndEnv(repo)
if err != nil {
return nil, err
}
......
package objectpool
import (
"bytes"
"context"
"os"
"path"
"gitlab.com/gitlab-org/gitaly-proto/go/gitalypb"
"gitlab.com/gitlab-org/gitaly/internal/git"
"gitlab.com/gitlab-org/gitaly/internal/helper"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/status"
)
// Clone a repository to a pool, without setting the alternates, is not the
// resposibility of this function.
func (o *ObjectPool) clone(ctx context.Context, repo *gitalypb.Repository) error {
repoPath, err := helper.GetRepoPath(repo)
if err != nil {
return err
}
targetDir := o.fullPath()
targetName := path.Base(targetDir)
if err != nil {
return err
}
cloneArgs := []string{"-C", path.Dir(targetDir), "clone", "--quiet", "--bare", "--local", repoPath, targetName}
cmd, err := git.CommandWithoutRepo(ctx, cloneArgs...)
if err != nil {
return err
}
if err := cmd.Wait(); err != nil {
return status.Error(codes.Internal, helper.SanitizeString(err.Error()))
}
return nil
}
func (o *ObjectPool) removeRefs(ctx context.Context) error {
var output bytes.Buffer
cmd, err := git.BareCommand(ctx, nil, &output, os.Stderr, nil, "--git-dir", o.fullPath(), "for-each-ref", "--format=delete %(refname)")
if err != nil {
return err
}
if err := cmd.Wait(); err != nil {
return err
}
updateRefCmd, err := git.BareCommand(ctx, &output, nil, os.Stderr, nil, "-C", o.fullPath(), "update-ref", "--stdin")
if err != nil {
return err
}
return updateRefCmd.Wait()
}
func (o *ObjectPool) removeHooksDir() error {
return os.RemoveAll(path.Join(o.fullPath(), "hooks"))
}
package objectpool
import (
"os"
"path"
"testing"
"github.com/stretchr/testify/require"
"gitlab.com/gitlab-org/gitaly/internal/testhelper"
)
func TestClone(t *testing.T) {
ctx, cancel := testhelper.Context()
defer cancel()
testRepo, _, cleanupFn := testhelper.NewTestRepo(t)
defer cleanupFn()
pool, err := NewObjectPool(1, testRepo.GetStorageName())
require.NoError(t, err)
subdir := path.Dir(pool.fullPath())
require.NoError(t, os.MkdirAll(subdir, 0755))
defer os.RemoveAll(subdir)
err = pool.clone(ctx, testRepo)
require.NoError(t, err)
require.DirExists(t, pool.fullPath())
require.DirExists(t, path.Join(pool.fullPath(), "objects"))
}
func TestRemoveRefs(t *testing.T) {
ctx, cancel := testhelper.Context()
defer cancel()
testRepo, _, cleanupFn := testhelper.NewTestRepo(t)
defer cleanupFn()
pool, err := NewObjectPool(1, testRepo.GetStorageName())
require.NoError(t, err)
subdir := path.Dir(pool.fullPath())
require.NoError(t, os.MkdirAll(subdir, 0755))
defer os.RemoveAll(subdir)
require.NoError(t, pool.clone(ctx, testRepo))
require.NoError(t, pool.removeRefs(ctx))
out := testhelper.MustRunCommand(t, nil, "git", "-C", pool.fullPath(), "for-each-ref")
require.Len(t, out, 0)
}
func TestCloneExistingPool(t *testing.T) {
ctx, cancel := testhelper.Context()
defer cancel()
testRepo, _, cleanupFn := testhelper.NewTestRepo(t)
defer cleanupFn()
pool, err := NewObjectPool(1, testRepo.GetStorageName())
require.NoError(t, err)
subdir := path.Dir(pool.fullPath())
require.NoError(t, os.MkdirAll(subdir, 0755))
defer os.RemoveAll(subdir)
err = pool.clone(ctx, testRepo)
require.NoError(t, err)
// Reclone on the directory
err = pool.clone(ctx, testRepo)
require.Error(t, err)
}
package objectpool
import (
"crypto/sha256"
"fmt"
"path"
)
const poolPrefix = "@pools"
// GetRelativePath will create the relative path to the ObjectPool from the
// storage path.
func (o *ObjectPool) GetRelativePath() string {
sum := sha256.Sum256([]byte(string(o.id)))
sumStr := fmt.Sprintf("%x", sum)
return path.Join(poolPrefix, sumStr[0:2], sumStr[2:4], sumStr[4:63])
}
// GetStorageName exposes the shard name, to satisfy the repository.GitRepo
// interface
func (o *ObjectPool) GetStorageName() string {
return o.storageName
}
func (o *ObjectPool) fullPath() string {
return path.Join(o.storagePath, o.GetRelativePath())
}
package objectpool
import (
"testing"
"github.com/stretchr/testify/require"
)
func TestGetRelativePath(t *testing.T) {
pool := &ObjectPool{id: 1}
require.Equal(t, "@pools/4b/f5/122f344554c53bde2ebb8cd2b7e3d1600ad631c385a5d7cce23c7785459", pool.GetRelativePath())
}
package objectpool
import (
"context"
"os"
"path"
"strings"
"gitlab.com/gitlab-org/gitaly-proto/go/gitalypb"
"gitlab.com/gitlab-org/gitaly/internal/helper"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/status"
)
// ObjectPool are a way to dedup objects between repositories, where the objects
// live in a pool in a distinct repository which is used as an alternate object
// store for other repositories.
type ObjectPool struct {
id uint32
storageName string
storagePath string
}
// NewObjectPool will initialize the object with the required data on the storage
// shard. If the shard cannot be found, this function returns an error
func NewObjectPool(id uint32, storageName string) (pool *ObjectPool, err error) {
storagePath, err := helper.GetStorageByName(storageName)
if err != nil {
return nil, err
}
return &ObjectPool{id: id, storageName: storageName, storagePath: storagePath}, nil
}
// GetGitAlternateObjectDirectories for object pools are empty, given pools are
// never a member of another pool, nor do they share Alternate objects with other
// repositories which the pool doesn't contain itself
func (o *ObjectPool) GetGitAlternateObjectDirectories() []string {
return []string{}
}
// GetGitObjectDirectory satisfies the repository.GitRepo interface, but is not
// used for ObjectPools
func (o *ObjectPool) GetGitObjectDirectory() string {
return ""
}
func (o *ObjectPool) exists() bool {
fi, err := os.Stat(o.fullPath())
if os.IsNotExist(err) {
return false
}
return fi.IsDir()
}
func (o *ObjectPool) isValid() bool {
if !o.exists() {
return false
}
return helper.IsGitDirectory(o.fullPath())
}
// Create will create a pool for a repository and pull the required data to this
// pool. `repo` that is passed also joins the repository.
func (o *ObjectPool) Create(ctx context.Context, repo *gitalypb.Repository) (err error) {
if strings.HasPrefix(repo.GetRelativePath(), "@hashed") {
return status.Errorf(codes.FailedPrecondition, "repository is not using hashed storage")
}
if o.exists() {
return status.Errorf(codes.FailedPrecondition, "pool already exists at: %v", o.GetRelativePath())
}
if err := os.MkdirAll(path.Dir(o.fullPath()), 0755); err != nil {
return status.Errorf(codes.Internal, "failed to create pool %s: %v", o.GetRelativePath(), err)
}
if err := o.clone(ctx, repo); err != nil {
return status.Error(codes.Internal, err.Error())
}
if err := o.removeHooksDir(); err != nil {
return status.Errorf(codes.Internal, "failed to remove the hooks dir")
}
if err := o.removeRemote(ctx, "origin"); err != nil {
return status.Errorf(codes.Internal, "failed to remove remote 'origin'")
}
if err := o.removeRefs(ctx); err != nil {
return status.Errorf(codes.Internal, "failed to remove cloned refs")
}
return nil
}
// Remove will remove the pool, and all its contents without preparing and/or
// updating the repositories depending on this object pool
// Subdirectories will remain to exist, and will never be cleaned up, even when
// these are empty.
func (o *ObjectPool) Remove(ctx context.Context) (err error) {
if err := os.RemoveAll(o.fullPath()); err != nil {
return status.Errorf(codes.Internal, "failed to delete %v from disk", o.GetRelativePath())
}
return nil
}
package objectpool
import (
"os"
"path"
"testing"
"github.com/stretchr/testify/require"
"gitlab.com/gitlab-org/gitaly/internal/testhelper"
)
func TestNewObjectPool(t *testing.T) {
_, err := NewObjectPool(1, "default")
require.NoError(t, err)
_, err = NewObjectPool(1, "mepmep")
require.Error(t, err)
}
func TestCreate(t *testing.T) {
ctx, cancel := testhelper.Context()
defer cancel()
testRepo, _, cleanupFn := testhelper.NewTestRepo(t)
defer cleanupFn()
pool, err := NewObjectPool(1, testRepo.GetStorageName())
require.NoError(t, err)
err = pool.Create(ctx, testRepo)
require.NoError(t, err)
defer pool.Remove(ctx)
require.True(t, pool.exists())
require.True(t, pool.isValid())
}
func TestCreateSubDirsExist(t *testing.T) {
ctx, cancel := testhelper.Context()
defer cancel()
testRepo, _, cleanupFn := testhelper.NewTestRepo(t)
defer cleanupFn()
pool, err := NewObjectPool(1, testRepo.GetStorageName())
defer pool.Remove(ctx)
require.NoError(t, err)
err = pool.Create(ctx, testRepo)
require.NoError(t, err)
pool.Remove(ctx)
// Recreate pool so the subdirs exist already
err = pool.Create(ctx, testRepo)
require.NoError(t, err)
}
func TestRemove(t *testing.T) {
ctx, cancel := testhelper.Context()
defer cancel()
testRepo, _, cleanupFn := testhelper.NewTestRepo(t)
defer cleanupFn()
pool, err := NewObjectPool(1, testRepo.GetStorageName())
require.NoError(t, err)
err = pool.Create(ctx, testRepo)
require.NoError(t, err)
pool.Remove(ctx)
require.False(t, pool.exists())
subdir := path.Dir(pool.fullPath())
fi, err := os.Stat(subdir)
require.NoError(t, err)
require.True(t, fi.IsDir())
}
package objectpool
import (
"context"
"gitlab.com/gitlab-org/gitaly/internal/git"
"gitlab.com/gitlab-org/gitaly/internal/helper"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/status"
)
func (o *ObjectPool) removeRemote(ctx context.Context, name string) error {
cmd, err := git.Command(ctx, o, "remote", "remove", name)
if err != nil {
return err
}
if err = cmd.Wait(); err != nil {
return status.Error(codes.Internal, helper.SanitizeString(err.Error()))
}
return nil
}
package objectpool
import (
"os"
"path"
"testing"
"github.com/stretchr/testify/require"
"gitlab.com/gitlab-org/gitaly/internal/testhelper"
)
func TestRemoveRemote(t *testing.T) {
ctx, cancel := testhelper.Context()
defer cancel()
testRepo, _, cleanupFn := testhelper.NewTestRepo(t)
defer cleanupFn()
pool, err := NewObjectPool(1, testRepo.GetStorageName())
require.NoError(t, err)
subdir := path.Dir(pool.fullPath())
require.NoError(t, os.MkdirAll(subdir, 0755))
defer os.RemoveAll(subdir)
require.NoError(t, pool.clone(ctx, testRepo))
require.NoError(t, pool.removeRemote(ctx, "origin"))
out := testhelper.MustRunCommand(t, nil, "git", "-C", pool.fullPath(), "remote")
require.Len(t, out, 0)
}
package repository
// GitRepo supplies an interface for executing `git.Command`s
type GitRepo interface {
GetStorageName() string
GetRelativePath() string
GetGitObjectDirectory() string
GetGitAlternateObjectDirectories() []string
}
......@@ -4,8 +4,8 @@ import (
"os"
"path"
"gitlab.com/gitlab-org/gitaly-proto/go/gitalypb"
"gitlab.com/gitlab-org/gitaly/internal/config"
"gitlab.com/gitlab-org/gitaly/internal/git/repository"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/status"
)
......@@ -14,7 +14,7 @@ import (
// RPC Repository message. The errors returned are gRPC errors with
// relevant error codes and should be passed back to gRPC without further
// decoration.
func GetRepoPath(repo *gitalypb.Repository) (string, error) {
func GetRepoPath(repo repository.GitRepo) (string, error) {
repoPath, err := GetPath(repo)
if err != nil {
return "", err
......@@ -34,7 +34,7 @@ func GetRepoPath(repo *gitalypb.Repository) (string, error) {
// GetPath returns the path of the repo passed as first argument. An error is
// returned when either the storage can't be found or the path includes
// constructs trying to perform directory traversal.
func GetPath(repo *gitalypb.Repository) (string, error) {
func GetPath(repo repository.GitRepo) (string, error) {
storagePath, err := GetStorageByName(repo.GetStorageName())
if err != nil {
return "", err
......
......@@ -2,6 +2,7 @@ package helper
import (
"os"
"regexp"
"strings"
)
......@@ -13,3 +14,13 @@ func ContainsPathTraversal(path string) bool {
strings.Contains(path, separator+".."+separator) ||
strings.HasSuffix(path, separator+"..")
}
// Pattern taken from Regular Expressions Cookbook, slightly modified though
// |Scheme |User |Named/IPv4 host|IPv6+ host
var hostPattern = regexp.MustCompile(`(?i)([a-z][a-z0-9+\-.]*://)([a-z0-9\-._~%!$&'()*+,;=:]+@)([a-z0-9\-._~%]+|\[[a-z0-9\-._~%!$&'()*+,;=:]+\])`)
// SanitizeString will clean password and tokens from URLs, and replace them
// with [FILTERED].
func SanitizeString(str string) string {
return hostPattern.ReplaceAllString(str, "$1[FILTERED]@$3$4")
}
......@@ -22,3 +22,21 @@ func TestContainsPathTraversal(t *testing.T) {
assert.Equal(t, tc.containsTraversal, ContainsPathTraversal(tc.path))
}
}
func TestSanitizeString(t *testing.T) {
testCases := []struct {
input string
output string
}{
{"https://foo_the_user@gitlab.com/foo/bar", "https://[FILTERED]@gitlab.com/foo/bar"},
{"https://foo_the_user:hUntEr1@gitlab.com/foo/bar", "https://[FILTERED]@gitlab.com/foo/bar"},
{"proto://user:password@gitlab.com", "proto://[FILTERED]@gitlab.com"},
{"some message proto://user:password@gitlab.com", "some message proto://[FILTERED]@gitlab.com"},
{"test", "test"},
{"ssh://@gitlab.com", "ssh://@gitlab.com"},
}
for _, tc := range testCases {
assert.Equal(t, tc.output, SanitizeString(tc.input))
}
}
package objectpool
import (
"context"
"gitlab.com/gitlab-org/gitaly-proto/go/gitalypb"
"gitlab.com/gitlab-org/gitaly/internal/git/objectpool"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/status"
)
func (s *server) CreateObjectPool(ctx context.Context, in *gitalypb.CreateObjectPoolRequest) (*gitalypb.CreateObjectPoolResponse, error) {
if in.GetRepository() == nil {
return nil, status.Errorf(codes.InvalidArgument, "no origin repository")
}
pool, err := poolForRequest(in)
if err != nil {
return nil, err
}
if err := pool.Create(ctx, in.GetRepository()); err != nil {
return nil, err
}
return &gitalypb.CreateObjectPoolResponse{}, nil
}
func (s *server) DeleteObjectPool(ctx context.Context, in *gitalypb.DeleteObjectPoolRequest) (*gitalypb.DeleteObjectPoolResponse, error) {
pool, err := poolForRequest(in)
if err != nil {
return nil, err
}
if err := pool.Remove(ctx); err != nil {
return nil, err
}
return &gitalypb.DeleteObjectPoolResponse{}, nil
}
type poolRequest interface {
GetPool() *gitalypb.ObjectPool
}
func poolForRequest(req poolRequest) (*objectpool.ObjectPool, error) {
reqPool := req.GetPool()
return objectpool.NewObjectPool(reqPool.GetId(), reqPool.GetStorageName())
}
package objectpool
import (
"gitlab.com/gitlab-org/gitaly-proto/go/gitalypb"
"gitlab.com/gitlab-org/gitaly/internal/rubyserver"
)
type server struct {
*rubyserver.Server
}
// NewServer creates a new instance of a gRPC repo server
func NewServer(rs *rubyserver.Server) gitalypb.ObjectPoolServiceServer {
return &server{rs}
}
......@@ -11,6 +11,7 @@ It is generated from these files:
diff.proto
namespace.proto
notifications.proto
objectpool.proto
operations.proto
ref.proto
remote.proto
......@@ -107,6 +108,11 @@ It has these top-level messages:
RenameNamespaceResponse
PostReceiveRequest
PostReceiveResponse
ObjectPool
CreateObjectPoolRequest
CreateObjectPoolResponse
DeleteObjectPoolRequest
DeleteObjectPoolResponse
UserCreateBranchRequest
UserCreateBranchResponse
UserUpdateBranchRequest
......
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: objectpool.proto
package gitalypb
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import (
context "golang.org/x/net/context"
grpc "google.golang.org/grpc"
)
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
type ObjectPool struct {
Id uint32 `protobuf:"varint,1,opt,name=id" json:"id,omitempty"`
StorageName string `protobuf:"bytes,2,opt,name=storage_name,json=storageName" json:"storage_name,omitempty"`
}
func (m *ObjectPool) Reset() { *m = ObjectPool{} }
func (m *ObjectPool) String() string { return proto.CompactTextString(m) }
func (*ObjectPool) ProtoMessage() {}
func (*ObjectPool) Descriptor() ([]byte, []int) { return fileDescriptor6, []int{0} }
func (m *ObjectPool) GetId() uint32 {
if m != nil {
return m.Id
}
return 0
}
func (m *ObjectPool) GetStorageName() string {
if m != nil {
return m.StorageName
}
return ""
}
// Creates an object pool from the repository. The client is responsible for
// joining this pool later with this repository.
type CreateObjectPoolRequest struct {
Pool *ObjectPool `protobuf:"bytes,1,opt,name=pool" json:"pool,omitempty"`
Repository *Repository `protobuf:"bytes,2,opt,name=repository" json:"repository,omitempty"`
}
func (m *CreateObjectPoolRequest) Reset() { *m = CreateObjectPoolRequest{} }
func (m *CreateObjectPoolRequest) String() string { return proto.CompactTextString(m) }
func (*CreateObjectPoolRequest) ProtoMessage() {}
func (*CreateObjectPoolRequest) Descriptor() ([]byte, []int) { return fileDescriptor6, []int{1} }
func (m *CreateObjectPoolRequest) GetPool() *ObjectPool {
if m != nil {
return m.Pool
}
return nil
}
func (m *CreateObjectPoolRequest) GetRepository() *Repository {
if m != nil {
return m.Repository
}
return nil
}
type CreateObjectPoolResponse struct {
}
func (m *CreateObjectPoolResponse) Reset() { *m = CreateObjectPoolResponse{} }
func (m *CreateObjectPoolResponse) String() string { return proto.CompactTextString(m) }
func (*CreateObjectPoolResponse) ProtoMessage() {}
func (*CreateObjectPoolResponse) Descriptor() ([]byte, []int) { return fileDescriptor6, []int{2} }
// Removes the directory from disk, callee is responsible for leaving the object
// pool before calling this RPC
type DeleteObjectPoolRequest struct {
Pool *ObjectPool `protobuf:"bytes,1,opt,name=pool" json:"pool,omitempty"`
}
func (m *DeleteObjectPoolRequest) Reset() { *m = DeleteObjectPoolRequest{} }
func (m *DeleteObjectPoolRequest) String() string { return proto.CompactTextString(m) }
func (*DeleteObjectPoolRequest) ProtoMessage() {}
func (*DeleteObjectPoolRequest) Descriptor() ([]byte, []int) { return fileDescriptor6, []int{3} }
func (m *DeleteObjectPoolRequest) GetPool() *ObjectPool {
if m != nil {
return m.Pool
}
return nil
}
type DeleteObjectPoolResponse struct {
}
func (m *DeleteObjectPoolResponse) Reset() { *m = DeleteObjectPoolResponse{} }
func (m *DeleteObjectPoolResponse) String() string { return proto.CompactTextString(m) }
func (*DeleteObjectPoolResponse) ProtoMessage() {}
func (*DeleteObjectPoolResponse) Descriptor() ([]byte, []int) { return fileDescriptor6, []int{4} }
func init() {
proto.RegisterType((*ObjectPool)(nil), "gitaly.ObjectPool")
proto.RegisterType((*CreateObjectPoolRequest)(nil), "gitaly.CreateObjectPoolRequest")
proto.RegisterType((*CreateObjectPoolResponse)(nil), "gitaly.CreateObjectPoolResponse")
proto.RegisterType((*DeleteObjectPoolRequest)(nil), "gitaly.DeleteObjectPoolRequest")
proto.RegisterType((*DeleteObjectPoolResponse)(nil), "gitaly.DeleteObjectPoolResponse")
}
// Reference imports to suppress errors if they are not otherwise used.
var _ context.Context
var _ grpc.ClientConn
// This is a compile-time assertion to ensure that this generated file
// is compatible with the grpc package it is being compiled against.
const _ = grpc.SupportPackageIsVersion4
// Client API for ObjectPoolService service
type ObjectPoolServiceClient interface {
CreateObjectPool(ctx context.Context, in *CreateObjectPoolRequest, opts ...grpc.CallOption) (*CreateObjectPoolResponse, error)
DeleteObjectPool(ctx context.Context, in *DeleteObjectPoolRequest, opts ...grpc.CallOption) (*DeleteObjectPoolResponse, error)
}
type objectPoolServiceClient struct {
cc *grpc.ClientConn
}
func NewObjectPoolServiceClient(cc *grpc.ClientConn) ObjectPoolServiceClient {
return &objectPoolServiceClient{cc}
}
func (c *objectPoolServiceClient) CreateObjectPool(ctx context.Context, in *CreateObjectPoolRequest, opts ...grpc.CallOption) (*CreateObjectPoolResponse, error) {
out := new(CreateObjectPoolResponse)
err := grpc.Invoke(ctx, "/gitaly.ObjectPoolService/CreateObjectPool", in, out, c.cc, opts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *objectPoolServiceClient) DeleteObjectPool(ctx context.Context, in *DeleteObjectPoolRequest, opts ...grpc.CallOption) (*DeleteObjectPoolResponse, error) {
out := new(DeleteObjectPoolResponse)
err := grpc.Invoke(ctx, "/gitaly.ObjectPoolService/DeleteObjectPool", in, out, c.cc, opts...)
if err != nil {
return nil, err
}
return out, nil
}
// Server API for ObjectPoolService service
type ObjectPoolServiceServer interface {
CreateObjectPool(context.Context, *CreateObjectPoolRequest) (*CreateObjectPoolResponse, error)
DeleteObjectPool(context.Context, *DeleteObjectPoolRequest) (*DeleteObjectPoolResponse, error)
}
func RegisterObjectPoolServiceServer(s *grpc.Server, srv ObjectPoolServiceServer) {
s.RegisterService(&_ObjectPoolService_serviceDesc, srv)
}
func _ObjectPoolService_CreateObjectPool_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(CreateObjectPoolRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(ObjectPoolServiceServer).CreateObjectPool(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/gitaly.ObjectPoolService/CreateObjectPool",
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(ObjectPoolServiceServer).CreateObjectPool(ctx, req.(*CreateObjectPoolRequest))
}
return interceptor(ctx, in, info, handler)
}
func _ObjectPoolService_DeleteObjectPool_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(DeleteObjectPoolRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(ObjectPoolServiceServer).DeleteObjectPool(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: "/gitaly.ObjectPoolService/DeleteObjectPool",
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(ObjectPoolServiceServer).DeleteObjectPool(ctx, req.(*DeleteObjectPoolRequest))
}
return interceptor(ctx, in, info, handler)
}
var _ObjectPoolService_serviceDesc = grpc.ServiceDesc{
ServiceName: "gitaly.ObjectPoolService",
HandlerType: (*ObjectPoolServiceServer)(nil),
Methods: []grpc.MethodDesc{
{
MethodName: "CreateObjectPool",
Handler: _ObjectPoolService_CreateObjectPool_Handler,
},
{
MethodName: "DeleteObjectPool",
Handler: _ObjectPoolService_DeleteObjectPool_Handler,
},
},
Streams: []grpc.StreamDesc{},
Metadata: "objectpool.proto",
}
func init() { proto.RegisterFile("objectpool.proto", fileDescriptor6) }
var fileDescriptor6 = []byte{
// 259 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x92, 0x31, 0x4f, 0xc3, 0x30,
0x10, 0x85, 0x9b, 0x08, 0x55, 0xe2, 0x5a, 0x50, 0xb9, 0xa5, 0x51, 0x16, 0x82, 0x07, 0xd4, 0x29,
0x43, 0xf8, 0x01, 0x08, 0xc1, 0x0c, 0xc8, 0x0c, 0x8c, 0xc8, 0x6d, 0x4e, 0xc5, 0x28, 0xed, 0x05,
0xdb, 0x45, 0xea, 0x0f, 0xe4, 0x7f, 0xa1, 0x38, 0x85, 0x44, 0x8d, 0x3c, 0xb1, 0xbe, 0x7b, 0xfa,
0xde, 0x7b, 0x96, 0x61, 0xc6, 0xcb, 0x0f, 0x5a, 0xb9, 0x9a, 0xb9, 0xca, 0x6b, 0xc3, 0x8e, 0x71,
0xbc, 0xd6, 0x4e, 0x55, 0xfb, 0x74, 0x6a, 0xdf, 0x95, 0xa1, 0xb2, 0x55, 0xc5, 0x2d, 0xc0, 0x93,
0x77, 0x3e, 0x33, 0x57, 0x78, 0x0e, 0xb1, 0x2e, 0x93, 0x28, 0x8b, 0x16, 0x67, 0x32, 0xd6, 0x25,
0x5e, 0xc1, 0xd4, 0x3a, 0x36, 0x6a, 0x4d, 0x6f, 0x5b, 0xb5, 0xa1, 0x24, 0xce, 0xa2, 0xc5, 0xa9,
0x9c, 0x1c, 0xb4, 0x47, 0xb5, 0x21, 0xb1, 0x83, 0xf9, 0xbd, 0x21, 0xe5, 0xa8, 0xc3, 0x48, 0xfa,
0xdc, 0x91, 0x75, 0x78, 0x0d, 0x27, 0x4d, 0xbe, 0xe7, 0x4d, 0x0a, 0xcc, 0xdb, 0x02, 0x79, 0xcf,
0xe8, 0xef, 0x58, 0x00, 0x18, 0xaa, 0xd9, 0x6a, 0xc7, 0x66, 0xef, 0x33, 0x7a, 0x6e, 0xf9, 0x77,
0x91, 0x3d, 0x97, 0x48, 0x21, 0x19, 0xc6, 0xda, 0x9a, 0xb7, 0x96, 0xc4, 0x1d, 0xcc, 0x1f, 0xa8,
0xa2, 0x7f, 0x54, 0x6a, 0xf0, 0x43, 0x44, 0x8b, 0x2f, 0xbe, 0x23, 0xb8, 0xe8, 0xe4, 0x17, 0x32,
0x5f, 0x7a, 0x45, 0xf8, 0x0a, 0xb3, 0xe3, 0x42, 0x78, 0xf9, 0xcb, 0x0f, 0xbc, 0x50, 0x9a, 0x85,
0x0d, 0x87, 0x2d, 0xa3, 0x06, 0x7c, 0x5c, 0xa5, 0x03, 0x07, 0x76, 0x76, 0xe0, 0xd0, 0x0a, 0x31,
0x5a, 0x8e, 0xfd, 0x0f, 0xb8, 0xf9, 0x09, 0x00, 0x00, 0xff, 0xff, 0x46, 0xa3, 0xd8, 0xf2, 0x2b,
0x02, 0x00, 0x00,
}
......@@ -28,7 +28,7 @@ type AddRemoteRequest struct {
func (m *AddRemoteRequest) Reset() { *m = AddRemoteRequest{} }
func (m *AddRemoteRequest) String() string { return proto.CompactTextString(m) }
func (*AddRemoteRequest) ProtoMessage() {}
func (*AddRemoteRequest) Descriptor() ([]byte, []int) { return fileDescriptor8, []int{0} }
func (*AddRemoteRequest) Descriptor() ([]byte, []int) { return fileDescriptor9, []int{0} }
func (m *AddRemoteRequest) GetRepository() *Repository {
if m != nil {
......@@ -64,7 +64,7 @@ type AddRemoteResponse struct {
func (m *AddRemoteResponse) Reset() { *m = AddRemoteResponse{} }
func (m *AddRemoteResponse) String() string { return proto.CompactTextString(m) }
func (*AddRemoteResponse) ProtoMessage() {}
func (*AddRemoteResponse) Descriptor() ([]byte, []int) { return fileDescriptor8, []int{1} }
func (*AddRemoteResponse) Descriptor() ([]byte, []int) { return fileDescriptor9, []int{1} }
type RemoveRemoteRequest struct {
Repository *Repository `protobuf:"bytes,1,opt,name=repository" json:"repository,omitempty"`
......@@ -74,7 +74,7 @@ type RemoveRemoteRequest struct {
func (m *RemoveRemoteRequest) Reset() { *m = RemoveRemoteRequest{} }
func (m *RemoveRemoteRequest) String() string { return proto.CompactTextString(m) }
func (*RemoveRemoteRequest) ProtoMessage() {}
func (*RemoveRemoteRequest) Descriptor() ([]byte, []int) { return fileDescriptor8, []int{2} }
func (*RemoveRemoteRequest) Descriptor() ([]byte, []int) { return fileDescriptor9, []int{2} }
func (m *RemoveRemoteRequest) GetRepository() *Repository {
if m != nil {
......@@ -97,7 +97,7 @@ type RemoveRemoteResponse struct {
func (m *RemoveRemoteResponse) Reset() { *m = RemoveRemoteResponse{} }
func (m *RemoveRemoteResponse) String() string { return proto.CompactTextString(m) }
func (*RemoveRemoteResponse) ProtoMessage() {}
func (*RemoveRemoteResponse) Descriptor() ([]byte, []int) { return fileDescriptor8, []int{3} }
func (*RemoveRemoteResponse) Descriptor() ([]byte, []int) { return fileDescriptor9, []int{3} }
func (m *RemoveRemoteResponse) GetResult() bool {
if m != nil {
......@@ -114,7 +114,7 @@ type FetchInternalRemoteRequest struct {
func (m *FetchInternalRemoteRequest) Reset() { *m = FetchInternalRemoteRequest{} }
func (m *FetchInternalRemoteRequest) String() string { return proto.CompactTextString(m) }
func (*FetchInternalRemoteRequest) ProtoMessage() {}
func (*FetchInternalRemoteRequest) Descriptor() ([]byte, []int) { return fileDescriptor8, []int{4} }
func (*FetchInternalRemoteRequest) Descriptor() ([]byte, []int) { return fileDescriptor9, []int{4} }
func (m *FetchInternalRemoteRequest) GetRepository() *Repository {
if m != nil {
......@@ -137,7 +137,7 @@ type FetchInternalRemoteResponse struct {
func (m *FetchInternalRemoteResponse) Reset() { *m = FetchInternalRemoteResponse{} }
func (m *FetchInternalRemoteResponse) String() string { return proto.CompactTextString(m) }
func (*FetchInternalRemoteResponse) ProtoMessage() {}
func (*FetchInternalRemoteResponse) Descriptor() ([]byte, []int) { return fileDescriptor8, []int{5} }
func (*FetchInternalRemoteResponse) Descriptor() ([]byte, []int) { return fileDescriptor9, []int{5} }
func (m *FetchInternalRemoteResponse) GetResult() bool {
if m != nil {
......@@ -157,7 +157,7 @@ type UpdateRemoteMirrorRequest struct {
func (m *UpdateRemoteMirrorRequest) Reset() { *m = UpdateRemoteMirrorRequest{} }
func (m *UpdateRemoteMirrorRequest) String() string { return proto.CompactTextString(m) }
func (*UpdateRemoteMirrorRequest) ProtoMessage() {}
func (*UpdateRemoteMirrorRequest) Descriptor() ([]byte, []int) { return fileDescriptor8, []int{6} }
func (*UpdateRemoteMirrorRequest) Descriptor() ([]byte, []int) { return fileDescriptor9, []int{6} }
func (m *UpdateRemoteMirrorRequest) GetRepository() *Repository {
if m != nil {
......@@ -200,7 +200,7 @@ type UpdateRemoteMirrorResponse struct {
func (m *UpdateRemoteMirrorResponse) Reset() { *m = UpdateRemoteMirrorResponse{} }
func (m *UpdateRemoteMirrorResponse) String() string { return proto.CompactTextString(m) }
func (*UpdateRemoteMirrorResponse) ProtoMessage() {}
func (*UpdateRemoteMirrorResponse) Descriptor() ([]byte, []int) { return fileDescriptor8, []int{7} }
func (*UpdateRemoteMirrorResponse) Descriptor() ([]byte, []int) { return fileDescriptor9, []int{7} }
type FindRemoteRepositoryRequest struct {
Remote string `protobuf:"bytes,1,opt,name=remote" json:"remote,omitempty"`
......@@ -209,7 +209,7 @@ type FindRemoteRepositoryRequest struct {
func (m *FindRemoteRepositoryRequest) Reset() { *m = FindRemoteRepositoryRequest{} }
func (m *FindRemoteRepositoryRequest) String() string { return proto.CompactTextString(m) }
func (*FindRemoteRepositoryRequest) ProtoMessage() {}
func (*FindRemoteRepositoryRequest) Descriptor() ([]byte, []int) { return fileDescriptor8, []int{8} }
func (*FindRemoteRepositoryRequest) Descriptor() ([]byte, []int) { return fileDescriptor9, []int{8} }
func (m *FindRemoteRepositoryRequest) GetRemote() string {
if m != nil {
......@@ -227,7 +227,7 @@ type FindRemoteRepositoryResponse struct {
func (m *FindRemoteRepositoryResponse) Reset() { *m = FindRemoteRepositoryResponse{} }
func (m *FindRemoteRepositoryResponse) String() string { return proto.CompactTextString(m) }
func (*FindRemoteRepositoryResponse) ProtoMessage() {}
func (*FindRemoteRepositoryResponse) Descriptor() ([]byte, []int) { return fileDescriptor8, []int{9} }
func (*FindRemoteRepositoryResponse) Descriptor() ([]byte, []int) { return fileDescriptor9, []int{9} }
func (m *FindRemoteRepositoryResponse) GetExists() bool {
if m != nil {
......@@ -244,7 +244,7 @@ type FindRemoteRootRefRequest struct {
func (m *FindRemoteRootRefRequest) Reset() { *m = FindRemoteRootRefRequest{} }
func (m *FindRemoteRootRefRequest) String() string { return proto.CompactTextString(m) }
func (*FindRemoteRootRefRequest) ProtoMessage() {}
func (*FindRemoteRootRefRequest) Descriptor() ([]byte, []int) { return fileDescriptor8, []int{10} }
func (*FindRemoteRootRefRequest) Descriptor() ([]byte, []int) { return fileDescriptor9, []int{10} }
func (m *FindRemoteRootRefRequest) GetRepository() *Repository {
if m != nil {
......@@ -267,7 +267,7 @@ type FindRemoteRootRefResponse struct {
func (m *FindRemoteRootRefResponse) Reset() { *m = FindRemoteRootRefResponse{} }
func (m *FindRemoteRootRefResponse) String() string { return proto.CompactTextString(m) }
func (*FindRemoteRootRefResponse) ProtoMessage() {}
func (*FindRemoteRootRefResponse) Descriptor() ([]byte, []int) { return fileDescriptor8, []int{11} }
func (*FindRemoteRootRefResponse) Descriptor() ([]byte, []int) { return fileDescriptor9, []int{11} }
func (m *FindRemoteRootRefResponse) GetRef() string {
if m != nil {
......@@ -563,9 +563,9 @@ var _RemoteService_serviceDesc = grpc.ServiceDesc{
Metadata: "remote.proto",
}
func init() { proto.RegisterFile("remote.proto", fileDescriptor8) }
func init() { proto.RegisterFile("remote.proto", fileDescriptor9) }
var fileDescriptor8 = []byte{
var fileDescriptor9 = []byte{
// 574 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x55, 0x4d, 0x6f, 0xd3, 0x30,
0x18, 0x26, 0x4b, 0xd7, 0xb5, 0xef, 0x3a, 0xd4, 0xba, 0xd5, 0x48, 0xb3, 0x4a, 0x74, 0x06, 0xa4,
......
......@@ -23,7 +23,7 @@ type ServerInfoRequest struct {
func (m *ServerInfoRequest) Reset() { *m = ServerInfoRequest{} }
func (m *ServerInfoRequest) String() string { return proto.CompactTextString(m) }
func (*ServerInfoRequest) ProtoMessage() {}
func (*ServerInfoRequest) Descriptor() ([]byte, []int) { return fileDescriptor10, []int{0} }
func (*ServerInfoRequest) Descriptor() ([]byte, []int) { return fileDescriptor11, []int{0} }
type ServerInfoResponse struct {
ServerVersion string `protobuf:"bytes,1,opt,name=server_version,json=serverVersion" json:"server_version,omitempty"`
......@@ -34,7 +34,7 @@ type ServerInfoResponse struct {
func (m *ServerInfoResponse) Reset() { *m = ServerInfoResponse{} }
func (m *ServerInfoResponse) String() string { return proto.CompactTextString(m) }
func (*ServerInfoResponse) ProtoMessage() {}
func (*ServerInfoResponse) Descriptor() ([]byte, []int) { return fileDescriptor10, []int{1} }
func (*ServerInfoResponse) Descriptor() ([]byte, []int) { return fileDescriptor11, []int{1} }
func (m *ServerInfoResponse) GetServerVersion() string {
if m != nil {
......@@ -67,7 +67,7 @@ func (m *ServerInfoResponse_StorageStatus) Reset() { *m = ServerInfoResp
func (m *ServerInfoResponse_StorageStatus) String() string { return proto.CompactTextString(m) }
func (*ServerInfoResponse_StorageStatus) ProtoMessage() {}
func (*ServerInfoResponse_StorageStatus) Descriptor() ([]byte, []int) {
return fileDescriptor10, []int{1, 0}
return fileDescriptor11, []int{1, 0}
}
func (m *ServerInfoResponse_StorageStatus) GetStorageName() string {
......@@ -169,9 +169,9 @@ var _ServerService_serviceDesc = grpc.ServiceDesc{
Metadata: "server.proto",
}
func init() { proto.RegisterFile("server.proto", fileDescriptor10) }
func init() { proto.RegisterFile("server.proto", fileDescriptor11) }
var fileDescriptor10 = []byte{
var fileDescriptor11 = []byte{
// 258 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x74, 0x91, 0xcf, 0x4a, 0xc3, 0x40,
0x10, 0xc6, 0x6d, 0x03, 0xa5, 0x9d, 0x34, 0xfe, 0x19, 0x2f, 0x35, 0x08, 0xd6, 0x80, 0x90, 0x53,
......
......@@ -30,7 +30,7 @@ type Repository struct {
func (m *Repository) Reset() { *m = Repository{} }
func (m *Repository) String() string { return proto.CompactTextString(m) }
func (*Repository) ProtoMessage() {}
func (*Repository) Descriptor() ([]byte, []int) { return fileDescriptor11, []int{0} }
func (*Repository) Descriptor() ([]byte, []int) { return fileDescriptor12, []int{0} }
func (m *Repository) GetStorageName() string {
if m != nil {
......@@ -84,7 +84,7 @@ type GitCommit struct {
func (m *GitCommit) Reset() { *m = GitCommit{} }
func (m *GitCommit) String() string { return proto.CompactTextString(m) }
func (*GitCommit) ProtoMessage() {}
func (*GitCommit) Descriptor() ([]byte, []int) { return fileDescriptor11, []int{1} }
func (*GitCommit) Descriptor() ([]byte, []int) { return fileDescriptor12, []int{1} }
func (m *GitCommit) GetId() string {
if m != nil {
......@@ -144,7 +144,7 @@ type CommitAuthor struct {
func (m *CommitAuthor) Reset() { *m = CommitAuthor{} }
func (m *CommitAuthor) String() string { return proto.CompactTextString(m) }
func (*CommitAuthor) ProtoMessage() {}
func (*CommitAuthor) Descriptor() ([]byte, []int) { return fileDescriptor11, []int{2} }
func (*CommitAuthor) Descriptor() ([]byte, []int) { return fileDescriptor12, []int{2} }
func (m *CommitAuthor) GetName() []byte {
if m != nil {
......@@ -174,7 +174,7 @@ type ExitStatus struct {
func (m *ExitStatus) Reset() { *m = ExitStatus{} }
func (m *ExitStatus) String() string { return proto.CompactTextString(m) }
func (*ExitStatus) ProtoMessage() {}
func (*ExitStatus) Descriptor() ([]byte, []int) { return fileDescriptor11, []int{3} }
func (*ExitStatus) Descriptor() ([]byte, []int) { return fileDescriptor12, []int{3} }
func (m *ExitStatus) GetValue() int32 {
if m != nil {
......@@ -192,7 +192,7 @@ type Branch struct {
func (m *Branch) Reset() { *m = Branch{} }
func (m *Branch) String() string { return proto.CompactTextString(m) }
func (*Branch) ProtoMessage() {}
func (*Branch) Descriptor() ([]byte, []int) { return fileDescriptor11, []int{4} }
func (*Branch) Descriptor() ([]byte, []int) { return fileDescriptor12, []int{4} }
func (m *Branch) GetName() []byte {
if m != nil {
......@@ -223,7 +223,7 @@ type Tag struct {
func (m *Tag) Reset() { *m = Tag{} }
func (m *Tag) String() string { return proto.CompactTextString(m) }
func (*Tag) ProtoMessage() {}
func (*Tag) Descriptor() ([]byte, []int) { return fileDescriptor11, []int{5} }
func (*Tag) Descriptor() ([]byte, []int) { return fileDescriptor12, []int{5} }
func (m *Tag) GetName() []byte {
if m != nil {
......@@ -277,7 +277,7 @@ type User struct {
func (m *User) Reset() { *m = User{} }
func (m *User) String() string { return proto.CompactTextString(m) }
func (*User) ProtoMessage() {}
func (*User) Descriptor() ([]byte, []int) { return fileDescriptor11, []int{6} }
func (*User) Descriptor() ([]byte, []int) { return fileDescriptor12, []int{6} }
func (m *User) GetGlId() string {
if m != nil {
......@@ -317,9 +317,9 @@ func init() {
proto.RegisterType((*User)(nil), "gitaly.User")
}
func init() { proto.RegisterFile("shared.proto", fileDescriptor11) }
func init() { proto.RegisterFile("shared.proto", fileDescriptor12) }
var fileDescriptor11 = []byte{
var fileDescriptor12 = []byte{
// 576 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x53, 0x41, 0x6f, 0xd4, 0x3c,
0x10, 0x55, 0xb2, 0xd9, 0x6d, 0x77, 0x36, 0xfd, 0xf4, 0x61, 0x7a, 0x88, 0x8a, 0xaa, 0x2e, 0xe1,
......
......@@ -28,7 +28,7 @@ type InfoRefsRequest struct {
func (m *InfoRefsRequest) Reset() { *m = InfoRefsRequest{} }
func (m *InfoRefsRequest) String() string { return proto.CompactTextString(m) }
func (*InfoRefsRequest) ProtoMessage() {}
func (*InfoRefsRequest) Descriptor() ([]byte, []int) { return fileDescriptor12, []int{0} }
func (*InfoRefsRequest) Descriptor() ([]byte, []int) { return fileDescriptor13, []int{0} }
func (m *InfoRefsRequest) GetRepository() *Repository {
if m != nil {
......@@ -58,7 +58,7 @@ type InfoRefsResponse struct {
func (m *InfoRefsResponse) Reset() { *m = InfoRefsResponse{} }
func (m *InfoRefsResponse) String() string { return proto.CompactTextString(m) }
func (*InfoRefsResponse) ProtoMessage() {}
func (*InfoRefsResponse) Descriptor() ([]byte, []int) { return fileDescriptor12, []int{1} }
func (*InfoRefsResponse) Descriptor() ([]byte, []int) { return fileDescriptor13, []int{1} }
func (m *InfoRefsResponse) GetData() []byte {
if m != nil {
......@@ -81,7 +81,7 @@ type PostUploadPackRequest struct {
func (m *PostUploadPackRequest) Reset() { *m = PostUploadPackRequest{} }
func (m *PostUploadPackRequest) String() string { return proto.CompactTextString(m) }
func (*PostUploadPackRequest) ProtoMessage() {}
func (*PostUploadPackRequest) Descriptor() ([]byte, []int) { return fileDescriptor12, []int{2} }
func (*PostUploadPackRequest) Descriptor() ([]byte, []int) { return fileDescriptor13, []int{2} }
func (m *PostUploadPackRequest) GetRepository() *Repository {
if m != nil {
......@@ -119,7 +119,7 @@ type PostUploadPackResponse struct {
func (m *PostUploadPackResponse) Reset() { *m = PostUploadPackResponse{} }
func (m *PostUploadPackResponse) String() string { return proto.CompactTextString(m) }
func (*PostUploadPackResponse) ProtoMessage() {}
func (*PostUploadPackResponse) Descriptor() ([]byte, []int) { return fileDescriptor12, []int{3} }
func (*PostUploadPackResponse) Descriptor() ([]byte, []int) { return fileDescriptor13, []int{3} }
func (m *PostUploadPackResponse) GetData() []byte {
if m != nil {
......@@ -147,7 +147,7 @@ type PostReceivePackRequest struct {
func (m *PostReceivePackRequest) Reset() { *m = PostReceivePackRequest{} }
func (m *PostReceivePackRequest) String() string { return proto.CompactTextString(m) }
func (*PostReceivePackRequest) ProtoMessage() {}
func (*PostReceivePackRequest) Descriptor() ([]byte, []int) { return fileDescriptor12, []int{4} }
func (*PostReceivePackRequest) Descriptor() ([]byte, []int) { return fileDescriptor13, []int{4} }
func (m *PostReceivePackRequest) GetRepository() *Repository {
if m != nil {
......@@ -206,7 +206,7 @@ type PostReceivePackResponse struct {
func (m *PostReceivePackResponse) Reset() { *m = PostReceivePackResponse{} }
func (m *PostReceivePackResponse) String() string { return proto.CompactTextString(m) }
func (*PostReceivePackResponse) ProtoMessage() {}
func (*PostReceivePackResponse) Descriptor() ([]byte, []int) { return fileDescriptor12, []int{5} }
func (*PostReceivePackResponse) Descriptor() ([]byte, []int) { return fileDescriptor13, []int{5} }
func (m *PostReceivePackResponse) GetData() []byte {
if m != nil {
......@@ -521,9 +521,9 @@ var _SmartHTTPService_serviceDesc = grpc.ServiceDesc{
Metadata: "smarthttp.proto",
}
func init() { proto.RegisterFile("smarthttp.proto", fileDescriptor12) }
func init() { proto.RegisterFile("smarthttp.proto", fileDescriptor13) }
var fileDescriptor12 = []byte{
var fileDescriptor13 = []byte{
// 423 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xb4, 0x53, 0xd1, 0x8a, 0xd3, 0x40,
0x14, 0x75, 0xd2, 0x6e, 0x65, 0x6f, 0xa3, 0x2d, 0x77, 0xd1, 0x0d, 0x01, 0xdd, 0x1a, 0x41, 0xf2,
......
......@@ -31,7 +31,7 @@ type SSHUploadPackRequest struct {
func (m *SSHUploadPackRequest) Reset() { *m = SSHUploadPackRequest{} }
func (m *SSHUploadPackRequest) String() string { return proto.CompactTextString(m) }
func (*SSHUploadPackRequest) ProtoMessage() {}
func (*SSHUploadPackRequest) Descriptor() ([]byte, []int) { return fileDescriptor13, []int{0} }
func (*SSHUploadPackRequest) Descriptor() ([]byte, []int) { return fileDescriptor14, []int{0} }
func (m *SSHUploadPackRequest) GetRepository() *Repository {
if m != nil {
......@@ -74,7 +74,7 @@ type SSHUploadPackResponse struct {
func (m *SSHUploadPackResponse) Reset() { *m = SSHUploadPackResponse{} }
func (m *SSHUploadPackResponse) String() string { return proto.CompactTextString(m) }
func (*SSHUploadPackResponse) ProtoMessage() {}
func (*SSHUploadPackResponse) Descriptor() ([]byte, []int) { return fileDescriptor13, []int{1} }
func (*SSHUploadPackResponse) Descriptor() ([]byte, []int) { return fileDescriptor14, []int{1} }
func (m *SSHUploadPackResponse) GetStdout() []byte {
if m != nil {
......@@ -116,7 +116,7 @@ type SSHReceivePackRequest struct {
func (m *SSHReceivePackRequest) Reset() { *m = SSHReceivePackRequest{} }
func (m *SSHReceivePackRequest) String() string { return proto.CompactTextString(m) }
func (*SSHReceivePackRequest) ProtoMessage() {}
func (*SSHReceivePackRequest) Descriptor() ([]byte, []int) { return fileDescriptor13, []int{2} }
func (*SSHReceivePackRequest) Descriptor() ([]byte, []int) { return fileDescriptor14, []int{2} }
func (m *SSHReceivePackRequest) GetRepository() *Repository {
if m != nil {
......@@ -180,7 +180,7 @@ type SSHReceivePackResponse struct {
func (m *SSHReceivePackResponse) Reset() { *m = SSHReceivePackResponse{} }
func (m *SSHReceivePackResponse) String() string { return proto.CompactTextString(m) }
func (*SSHReceivePackResponse) ProtoMessage() {}
func (*SSHReceivePackResponse) Descriptor() ([]byte, []int) { return fileDescriptor13, []int{3} }
func (*SSHReceivePackResponse) Descriptor() ([]byte, []int) { return fileDescriptor14, []int{3} }
func (m *SSHReceivePackResponse) GetStdout() []byte {
if m != nil {
......@@ -213,7 +213,7 @@ type SSHUploadArchiveRequest struct {
func (m *SSHUploadArchiveRequest) Reset() { *m = SSHUploadArchiveRequest{} }
func (m *SSHUploadArchiveRequest) String() string { return proto.CompactTextString(m) }
func (*SSHUploadArchiveRequest) ProtoMessage() {}
func (*SSHUploadArchiveRequest) Descriptor() ([]byte, []int) { return fileDescriptor13, []int{4} }
func (*SSHUploadArchiveRequest) Descriptor() ([]byte, []int) { return fileDescriptor14, []int{4} }
func (m *SSHUploadArchiveRequest) GetRepository() *Repository {
if m != nil {
......@@ -241,7 +241,7 @@ type SSHUploadArchiveResponse struct {
func (m *SSHUploadArchiveResponse) Reset() { *m = SSHUploadArchiveResponse{} }
func (m *SSHUploadArchiveResponse) String() string { return proto.CompactTextString(m) }
func (*SSHUploadArchiveResponse) ProtoMessage() {}
func (*SSHUploadArchiveResponse) Descriptor() ([]byte, []int) { return fileDescriptor13, []int{5} }
func (*SSHUploadArchiveResponse) Descriptor() ([]byte, []int) { return fileDescriptor14, []int{5} }
func (m *SSHUploadArchiveResponse) GetStdout() []byte {
if m != nil {
......@@ -513,9 +513,9 @@ var _SSHService_serviceDesc = grpc.ServiceDesc{
Metadata: "ssh.proto",
}
func init() { proto.RegisterFile("ssh.proto", fileDescriptor13) }
func init() { proto.RegisterFile("ssh.proto", fileDescriptor14) }
var fileDescriptor13 = []byte{
var fileDescriptor14 = []byte{
// 452 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x53, 0xc1, 0x6e, 0xd3, 0x40,
0x10, 0xc5, 0x89, 0x13, 0xc8, 0xc4, 0x45, 0xd1, 0xd2, 0x16, 0x2b, 0x02, 0x6a, 0xcc, 0xc5, 0x07,
......