internals

package
v0.0.0-...-ad8cac9 Latest Latest
Warning

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

Go to latest
Published: Oct 3, 2024 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Configuration

type Configuration struct {
	CommitStatsTimeoutInSec int    `env:"COMMIT_STATS_TIMEOUT_IN_SEC" envDefault:"2"`
	EnableFileStats         bool   `env:"ENABLE_FILE_STATS" envDefault:"false"`
	GitHistoryCount         int    `env:"GIT_HISTORY_COUNT" envDefault:"15"`
	MinLimit                int    `env:"MIN_LIMIT_FOR_PVC" envDefault:"1"` // in MB
	UseGitCli               bool   `env:"USE_GIT_CLI" envDefault:"false"`
	UseGitCliAnalytics      bool   `env:"USE_GIT_CLI_ANALYTICS" envDefault:"false"` // This flag is used to compute commitDiff using git-cli only for analytics
	AnalyticsDebug          bool   `env:"ANALYTICS_DEBUG" envDefault:"false"`
	CliCmdTimeoutGlobal     int    `env:"CLI_CMD_TIMEOUT_GLOBAL_SECONDS" envDefault:"0"`
	CliCmdTimeoutJson       string `env:"CLI_CMD_TIMEOUT_JSON" envDefault:""`
	GoGitTimeout            int    `env:"GOGIT_TIMEOUT_SECONDS" envDefault:"10" `
}

func ParseConfiguration

func ParseConfiguration() (*Configuration, error)

type RepositoryLock

type RepositoryLock struct {
	Mutex sync.Mutex
	// contains filtered or unexported fields
}

type RepositoryLocker

type RepositoryLocker struct {
	Mutex sync.Mutex
	Bank  map[int]*RepositoryLock
	// contains filtered or unexported fields
}

func NewRepositoryLocker

func NewRepositoryLocker(logger *zap.SugaredLogger) *RepositoryLocker

func (*RepositoryLocker) LeaseLocker

func (locker *RepositoryLocker) LeaseLocker(RepositoryId int) *RepositoryLock

func (*RepositoryLocker) ReturnLocker

func (locker *RepositoryLocker) ReturnLocker(appId int)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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