Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func InterestingLogLines ¶
InterestingLogLines scans newest-to-oldest for error-like lines and returns up to max matches in original chronological order.
Types ¶
type Context ¶
type Context struct {
Project *discover.Project
Config *compose.Config // MAY BE NIL
Inspect func(containerID string) (*docker.InspectInfo, error)
Logs func(containerID string, tail int) ([]string, error)
Now time.Time
}
Context provides the static and runtime inputs used by doctor rules.
type Finding ¶
type Finding struct {
RuleID, Service, Title, Detail string
Severity Severity
Evidence, Suggestion []string
}
Finding is one actionable diagnosis from a doctor rule.
type RootCause ¶
type RootCause struct {
Culprits []string
Chains map[string][]string // blocked -> path to culprit
CriticalPath []string
FirstLog map[string]string
}
RootCause summarizes the likely service(s) causing startup blockage.
func FindRootCause ¶
FindRootCause traces blocked services back to failed, unhealthy, or restart-looping dependency endpoints. It returns nil when the graph has no blocked or broken services to explain.
type Rule ¶
Rule checks the doctor context and returns zero or more findings.
func DefaultRules ¶
func DefaultRules() []Rule
DefaultRules returns the built-in Phase 2 doctor rule set.
Click to show internal directories.
Click to hide internal directories.