Documentation
¶
Index ¶
- Variables
- func CrashID(event CrashEvent) string
- func DecodeRevision(reader io.Reader) ([]string, error)
- type Change
- func Detect(cluster string, delta index.Delta, at time.Time) (Change, bool)
- func DetectAll(cluster string, delta index.Delta, at time.Time) []Change
- func DetectContinuous(cluster string, delta index.Delta, at time.Time) []Change
- func Reconstruct(cluster string, records []index.Record, now time.Time) []Change
- type CrashEvent
- type CrashPage
- type CrashQuery
- type FieldChange
- type Gap
- type Lease
- type Page
- type Query
- type Store
- func (store *Store) Append(changes []Change, now time.Time) error
- func (store *Store) BreakLogs(now time.Time) (breaklogs.State, error)
- func (store *Store) CheckCaptureLease(owner string) error
- func (store *Store) ClaimLease(owner string, now time.Time, ttl time.Duration) error
- func (store *Store) Commit(changes []Change, gaps []Gap, coverage map[string]Gap, owner string, ...) error
- func (store *Store) CommitBreakLogs(items []breaklogs.Snapshot, gaps []breaklogs.Gap, job, owner string, ...) error
- func (store *Store) CommitCapture(changes []Change, gaps []Gap, coverage map[string]Gap, owner string, ...) error
- func (store *Store) MarkGap(gap Gap) error
- func (store *Store) Query(query Query, now time.Time) (Page, error)
- func (store *Store) QueryCrashes(query CrashQuery, now time.Time) (CrashPage, error)
- func (store *Store) ReadWindow(from, to, now time.Time) (Page, error)
- func (store *Store) ReleaseLease(owner string) error
- func (store *Store) RenewLease(owner string, now time.Time, ttl time.Duration) error
- func (store *Store) TimelineWindow(since, until time.Time) ([]Change, []CrashEvent, []Gap, error)
- type Type
Constants ¶
This section is empty.
Variables ¶
Functions ¶
func CrashID ¶ added in v1.4.31
func CrashID(event CrashEvent) string
Types ¶
type Change ¶
type Change struct {
RootUID string `json:"root_uid,omitempty"`
ID string `json:"id"`
Cluster string `json:"cluster"`
Kind string `json:"kind"`
Namespace string `json:"namespace,omitempty"`
Name string `json:"name"`
UID string `json:"uid"`
Type Type `json:"type"`
Fields []FieldChange `json:"fields,omitempty"`
At time.Time `json:"at"`
Service string `json:"service,omitempty"`
Source string `json:"source,omitempty"`
Revision string `json:"revision,omitempty"`
FieldsTruncated bool `json:"fields_truncated,omitempty"`
Coalesced bool `json:"coalesced,omitempty"`
// contains filtered or unexported fields
}
func DetectContinuous ¶ added in v1.4.31
type CrashEvent ¶ added in v1.4.31
type CrashEvent struct {
ID string `json:"id"`
Sequence uint64 `json:"sequence"`
Cluster string `json:"cluster"`
Namespace string `json:"namespace"`
Pod string `json:"pod"`
PodUID string `json:"pod_uid"`
RootUID string `json:"root_uid"`
RootKind string `json:"root_kind"`
RootName string `json:"root_name"`
AncestryPartial bool `json:"ancestry_partial,omitempty"`
Container string `json:"container"`
Init bool `json:"init,omitempty"`
Type string `json:"type"`
TerminationSlot string `json:"termination_slot,omitempty"`
WaitingReason string `json:"waiting_reason,omitempty"`
Reason string `json:"reason,omitempty"`
ExitCode int32 `json:"exit_code"`
Signal int32 `json:"signal,omitempty"`
RestartCount int32 `json:"restart_count"`
At time.Time `json:"at"`
TimeSource string `json:"time_source"`
ObservedAt time.Time `json:"observed_at"`
}
func (CrashEvent) Valid ¶ added in v1.4.31
func (event CrashEvent) Valid() bool
type CrashPage ¶ added in v1.4.31
type CrashPage struct {
CrashCount int `json:"crash_count"`
Items []CrashEvent `json:"items"`
Next string `json:"next,omitempty"`
Since time.Time `json:"since"`
Until time.Time `json:"until"`
RetentionFrom time.Time `json:"retention_from"`
RetentionBasis string `json:"retention_basis"`
StartedAt time.Time `json:"started_at"`
Gaps []Gap `json:"gaps"`
CaptureGaps []Gap `json:"capture_gaps"`
Coverage map[string]Gap `json:"coverage"`
Limitations []string `json:"limitations"`
}
type CrashQuery ¶ added in v1.4.31
type CrashQuery struct {
PodUID string
Since time.Time
Until time.Time
Namespace string
RootUID string
Limit int
Cursor string
}
CrashQuery bounds observation time; CrashEvent.At remains the actual event time.
type FieldChange ¶
type Store ¶
type Store struct {
// contains filtered or unexported fields
}
func (*Store) Append ¶
Append adds projected changes and evicts only the oldest records as required by bounds.
func (*Store) CheckCaptureLease ¶ added in v1.4.32
func (*Store) ClaimLease ¶ added in v1.4.31
func (*Store) CommitBreakLogs ¶ added in v1.4.32
func (*Store) CommitCapture ¶ added in v1.4.31
func (*Store) MarkGap ¶
MarkGap records a bounded interval for which the timeline cannot guarantee completeness.
func (*Store) QueryCrashes ¶ added in v1.4.31
func (*Store) ReadWindow ¶ added in v1.4.31
func (*Store) ReleaseLease ¶ added in v1.4.31
func (*Store) RenewLease ¶ added in v1.4.31
func (*Store) TimelineWindow ¶ added in v1.4.32
TimelineWindow takes one scoped retained journal snapshot. Filtering and display paging happen after sources are merged, never independently per type.
type Type ¶
type Type string
const ( Created Type = "created" Deleted Type = "deleted" ImageChanged Type = "image_changed" ReplicasChanged Type = "replicas_changed" SpecChanged Type = "spec_changed" RolloutStarted Type = "rollout_started" RolloutCompleted Type = "rollout_completed" RolloutStalled Type = "rollout_stalled" ConfigRefChanged Type = "config_ref_changed" ConfigChanged Type = "config_changed" WarningBurst Type = "warning_burst" )
Click to show internal directories.
Click to hide internal directories.