rubyserver

package
v14.10.5 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 30, 2022 License: MIT Imports: 33 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ConnectTimeout = 40 * time.Second

ConnectTimeout is the timeout for establishing a connection to the gitaly-ruby process.

Functions

func Proxy

func Proxy(recvSend func() error) (err error)

Proxy calls recvSend until it receives an error. The error is returned to the caller unless it is io.EOF.

func SetHeaders

func SetHeaders(ctx context.Context, locator storage.Locator, repo *gitalypb.Repository) (context.Context, error)

SetHeaders adds headers that tell gitaly-ruby the full path to the repository.

Types

type CloseSender

type CloseSender interface {
	CloseSend() error
}

CloseSender captures the CloseSend method from gRPC streams.

type Server

type Server struct {
	// contains filtered or unexported fields
}

Server represents a gitaly-ruby helper process.

func New

func New(cfg config.Cfg, gitCmdFactory git.CommandFactory) *Server

New returns a new instance of the server.

func (*Server) BlobServiceClient

func (s *Server) BlobServiceClient(ctx context.Context) (gitalypb.BlobServiceClient, error)

BlobServiceClient returns a BlobServiceClient instance that is configured to connect to the running Ruby server. This assumes Start() has been called already.

func (*Server) CommitServiceClient

func (s *Server) CommitServiceClient(ctx context.Context) (gitalypb.CommitServiceClient, error)

CommitServiceClient returns a CommitServiceClient instance that is configured to connect to the running Ruby server. This assumes Start() has been called already.

func (*Server) DiffServiceClient

func (s *Server) DiffServiceClient(ctx context.Context) (gitalypb.DiffServiceClient, error)

DiffServiceClient returns a DiffServiceClient instance that is configured to connect to the running Ruby server. This assumes Start() has been called already.

func (*Server) OperationServiceClient

func (s *Server) OperationServiceClient(ctx context.Context) (gitalypb.OperationServiceClient, error)

OperationServiceClient returns a OperationServiceClient instance that is configured to connect to the running Ruby server. This assumes Start() has been called already.

func (*Server) RefServiceClient

func (s *Server) RefServiceClient(ctx context.Context) (gitalypb.RefServiceClient, error)

RefServiceClient returns a RefServiceClient instance that is configured to connect to the running Ruby server. This assumes Start() has been called already.

func (*Server) RemoteServiceClient

func (s *Server) RemoteServiceClient(ctx context.Context) (gitalypb.RemoteServiceClient, error)

RemoteServiceClient returns a RemoteServiceClient instance that is configured to connect to the running Ruby server. This assumes Start() has been called already.

func (*Server) RepositoryServiceClient

func (s *Server) RepositoryServiceClient(ctx context.Context) (gitalypb.RepositoryServiceClient, error)

RepositoryServiceClient returns a RefServiceClient instance that is configured to connect to the running Ruby server. This assumes Start() has been called already.

func (*Server) Start

func (s *Server) Start() error

Start spawns the Ruby server.

func (*Server) Stop

func (s *Server) Stop()

Stop shuts down the gitaly-ruby helper process and cleans up resources.

func (*Server) WikiServiceClient

func (s *Server) WikiServiceClient(ctx context.Context) (gitalypb.WikiServiceClient, error)

WikiServiceClient returns a WikiServiceClient instance that is configured to connect to the running Ruby server. This assumes Start() has been called already.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL