Documentation ¶
Index ¶
- Constants
- Variables
- type Connector
- type DelegateConn
- type Lock
- type LockDB
- type LockFactory
- type LockID
- func NewBuildTrackingLockID(buildID int) LockID
- func NewContainerCreatingLockID(containerID int) LockID
- func NewPipelineSchedulingLockLockID(pipelineID int) LockID
- func NewResourceCheckingForJobLockID(jobID int) LockID
- func NewResourceConfigCheckingLockID(resourceConfigID int) LockID
- func NewResourceTypeCheckingLockID(resourceTypeID int) LockID
- func NewTaskLockID(taskName string) LockID
- func NewVolumeCreatingLockID(volumeID int) LockID
- type PgxConnector
- type RetryableConn
Constants ¶
View Source
const ( LockTypeResourceConfigChecking = iota LockTypeResourceTypeChecking LockTypeBuildTracking LockTypePipelineScheduling LockTypeResourceCheckingForJob LockTypeBatch LockTypeVolumeCreating LockTypeContainerCreating )
Variables ¶
View Source
var ErrLostLock = errors.New("lock was lost while held, possibly due to connection breakage")
Functions ¶
This section is empty.
Types ¶
type Connector ¶
type Connector interface {
Connect() (DelegateConn, error)
}
type DelegateConn ¶
type LockFactory ¶
func NewLockFactory ¶
func NewLockFactory(conn *RetryableConn) LockFactory
func NewTestLockFactory ¶
func NewTestLockFactory(db LockDB) LockFactory
type LockID ¶
type LockID []int
func NewBuildTrackingLockID ¶
func NewTaskLockID ¶
func NewVolumeCreatingLockID ¶
type PgxConnector ¶
type PgxConnector struct {
PgxConfig pgx.ConnConfig
}
func (PgxConnector) Connect ¶
func (c PgxConnector) Connect() (DelegateConn, error)
type RetryableConn ¶
type RetryableConn struct { Connector Connector Conn DelegateConn // *pgx.Conn }
func (*RetryableConn) Exec ¶
func (c *RetryableConn) Exec(sql string, arguments ...interface{}) (pgx.CommandTag, error)
Directories ¶
Path | Synopsis |
---|---|
This file was generated by counterfeiter This file was generated by counterfeiter This file was generated by counterfeiter This file was generated by counterfeiter This file was generated by counterfeiter
|
This file was generated by counterfeiter This file was generated by counterfeiter This file was generated by counterfeiter This file was generated by counterfeiter This file was generated by counterfeiter |
Click to show internal directories.
Click to hide internal directories.