Documentation
¶
Index ¶
- Constants
- func StaleChecks(checks []forge.Check, head string, now time.Time) bool
- type Authority
- type AuthorityBlocker
- type Companion
- type Configuration
- type Gate
- type Operation
- type Qualification
- type ReplacementProof
- type Revalidation
- type Service
- func (s *Service) Cancel(ctx context.Context, session auth.Session, org, id string, expected int64, ...) (Operation, error)
- func (s *Service) Config(ctx context.Context, session auth.Session, org, repo string) (Configuration, error)
- func (s *Service) Get(ctx context.Context, session auth.Session, org, id string) (Operation, error)
- func (s *Service) Inspect(ctx context.Context, session auth.Session, ...) (Gate, error)
- func (s *Service) List(ctx context.Context, session auth.Session, org, repo, change, cursor string, ...) (domain.Page[Operation], error)
- func (s *Service) Observe(ctx context.Context, org, id string) (Operation, error)
- func (s *Service) ObserveBotRepair(ctx context.Context, org, task string) error
- func (s *Service) PutConfig(ctx context.Context, session auth.Session, org, repo string, in Configuration, ...) (Configuration, error)
- func (s *Service) Reconcile(ctx context.Context, session auth.Session, org, id string, expected int64, ...) (Operation, error)
- func (s *Service) RegisterChangeAuthority(...)
- func (s *Service) Request(ctx context.Context, session auth.Session, org, gateID, key, request string) (Operation, error)
- func (s *Service) Revalidations(ctx context.Context, session auth.Session, org, repo, change string) ([]Revalidation, error)
- func (s *Service) Run(ctx context.Context) error
- type Snapshot
Constants ¶
View Source
const CheckFreshness = 24 * time.Hour
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Authority ¶
type Authority struct {
Blockers []string
CIConfigSHA256 string
ExecutionPublisher string
CompanionsBlocked bool
PathsVerified bool
ValidationHead string
ValidationTarget string
ValidationReference string
BehaviourRequired bool
BehaviourHead string
BehaviourTarget string
BehaviourReference string
MergeControlled bool
CooperationVerified bool
Qualified bool
ExactHeadEnforced bool
QualificationReference string
ReforgeEnforced bool
Paths []string
Usage policy.Limits
}
type AuthorityBlocker ¶
type AuthorityBlocker struct{ Reason string }
func (*AuthorityBlocker) Error ¶
func (b *AuthorityBlocker) Error() string
type Companion ¶
type Companion struct {
TaskID string `json:"task_id"`
FindingID string `json:"finding_id"`
ChangeID string `json:"change_id"`
HeadSHA string `json:"head_sha"`
ObservedHeadSHA string `json:"observed_head_sha"`
Branch string `json:"branch"`
TargetBranch string `json:"target_branch"`
SourceChangeID string `json:"source_change_id"`
SourceHeadSHA string `json:"source_head_sha"`
SourceBranch string `json:"source_branch"`
OwnerReplacement bool `json:"owner_replacement"`
ReplacesBranch string `json:"replaces_branch,omitempty"`
MergeSHA string `json:"merge_sha"`
Supersession []ReplacementProof `json:"supersession,omitempty"`
State string `json:"state"`
}
type Configuration ¶
type Configuration struct {
RepositoryID string `json:"repository_id"`
Version int64 `json:"version"`
Enabled bool `json:"enabled"`
InspectorConnectionID string `json:"inspector_connection_id,omitempty"`
CheckPublishers map[string]string `json:"check_publishers"`
CooperationReference string `json:"cooperation_reference"`
Qualification Qualification `json:"qualification"`
}
type Gate ¶
type Gate struct {
ReforgeEnforced bool `json:"reforge_enforced,omitempty"`
Phase string `json:"phase"`
Companions []Companion `json:"companions"`
Paths []string `json:"paths"`
ChangedLines int64 `json:"changed_lines"`
ConfigurationVersion int64 `json:"configuration_version"`
ID string `json:"id"`
RepositoryID string `json:"repository_id"`
ConnectionID string `json:"connection_id"`
ConnectionVersion int64 `json:"connection_version"`
Method string `json:"method"`
Snapshot Snapshot `json:"snapshot"`
Decision policy.Result `json:"decision"`
Binding policy.Binding `json:"binding"`
ExpiresAt time.Time `json:"expires_at"`
}
type Operation ¶
type Operation struct {
ID string `json:"id"`
RepositoryID string `json:"repository_id"`
GateID string `json:"gate_id"`
RequestedGateID string `json:"requested_gate_id"`
NativeQueueID string `json:"native_queue_id,omitempty"`
ChangeID string `json:"change_id"`
State string `json:"state"`
Reason string `json:"reason"`
CancelRequested bool `json:"cancel_requested"`
NativeResult *forge.MergeResult `json:"native_result,omitempty"`
Version int64 `json:"version"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
}
type Qualification ¶
type Qualification struct {
CIConfigSHA256 string `json:"ci_config_sha256,omitempty"`
Provider string `json:"provider"`
ServerVersion string `json:"server_version"`
ConnectionVersion int64 `json:"connection_version"`
InspectorVersion int64 `json:"inspector_version"`
EvidenceReference string `json:"evidence_reference"`
EvidenceSHA256 string `json:"evidence_sha256"`
VerifiedAt time.Time `json:"verified_at"`
ExpiresAt time.Time `json:"expires_at"`
ExactHead bool `json:"exact_head"`
StrictTarget bool `json:"strict_target"`
QueueExecutionGate bool `json:"queue_execution_gate"`
}
type ReplacementProof ¶
type ReplacementProof struct {
TaskID string `json:"task_id"`
FindingID string `json:"finding_id"`
ChangeID string `json:"change_id"`
CandidateSHA string `json:"candidate_sha"`
Branch string `json:"branch"`
TargetBranch string `json:"target_branch"`
SourceChangeID string `json:"source_change_id"`
SourceHeadSHA string `json:"source_head_sha"`
SourceBranch string `json:"source_branch"`
ObservedHeadSHA string `json:"observed_head_sha"`
MergeSHA string `json:"merge_sha"`
}
type Revalidation ¶
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
func (*Service) ObserveBotRepair ¶
func (*Service) RegisterChangeAuthority ¶
func (*Service) Revalidations ¶
type Snapshot ¶
type Snapshot = forge.MergeEvidence
Click to show internal directories.
Click to hide internal directories.