cloudsource

package
v1.0.2002 Latest Latest
Warning

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

Go to latest
Published: Sep 28, 2021 License: MIT Imports: 18 Imported by: 0

Documentation

Overview

Package cloudsource is a generated GoMock package.

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrNonCloneableEvent = errors.New("The event is not cloneable")
	ErrNoManifest        = errors.New("The repository has no manifest at the pushed commit")
)

Functions

This section is empty.

Types

type Handler

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

func NewHandler

func NewHandler(pubsubapiClient pubsubapi.Client, service Service) Handler

func (*Handler) PostPubsubEvent

func (h *Handler) PostPubsubEvent(c *gin.Context)

type MockService

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

MockService is a mock of Service interface.

func NewMockService

func NewMockService(ctrl *gomock.Controller) *MockService

NewMockService creates a new mock instance.

func (*MockService) CreateJobForCloudSourcePush

func (m *MockService) CreateJobForCloudSourcePush(ctx context.Context, notification cloudsourceapi.PubSubNotification) error

CreateJobForCloudSourcePush mocks base method.

func (*MockService) EXPECT

func (m *MockService) EXPECT() *MockServiceMockRecorder

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockService) IsAllowedProject

func (m *MockService) IsAllowedProject(ctx context.Context, notification cloudsourceapi.PubSubNotification) (bool, []*contracts.Organization)

IsAllowedProject mocks base method.

type MockServiceMockRecorder

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

MockServiceMockRecorder is the mock recorder for MockService.

func (*MockServiceMockRecorder) CreateJobForCloudSourcePush

func (mr *MockServiceMockRecorder) CreateJobForCloudSourcePush(ctx, notification interface{}) *gomock.Call

CreateJobForCloudSourcePush indicates an expected call of CreateJobForCloudSourcePush.

func (*MockServiceMockRecorder) IsAllowedProject

func (mr *MockServiceMockRecorder) IsAllowedProject(ctx, notification interface{}) *gomock.Call

IsAllowedProject indicates an expected call of IsAllowedProject.

type Service

type Service interface {
	CreateJobForCloudSourcePush(ctx context.Context, notification cloudsourceapi.PubSubNotification) (err error)
	IsAllowedProject(ctx context.Context, notification cloudsourceapi.PubSubNotification) (isAllowed bool, organizations []*contracts.Organization)
}

Service handles pubsub events for Cloud Source Repository integration

func NewLoggingService

func NewLoggingService(s Service) Service

NewLoggingService returns a new instance of a logging Service.

func NewMetricsService

func NewMetricsService(s Service, requestCount metrics.Counter, requestLatency metrics.Histogram) Service

NewMetricsService returns a new instance of a metrics Service.

func NewService

func NewService(config *api.APIConfig, cloudsourceapiClient cloudsourceapi.Client, pubsubapiClient pubsubapi.Client, estafetteService estafette.Service, queueService queue.Service) Service

NewService returns a new bitbucket.Service

func NewTracingService

func NewTracingService(s Service) Service

NewTracingService returns a new instance of a tracing Service.

Jump to

Keyboard shortcuts

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