Documentation
¶
Index ¶
- func BuildSnapshotID(windowStart, windowEnd, topologyVersion string) string
- func MarshalCanonical(env Envelope) ([]byte, error)
- func TopologyDigest(mdl model.ResilienceModel) (string, error)
- func WriteToFile(path string, env Envelope) error
- type Counts
- type CoverageSummary
- type DiffSummary
- type DiscoveryDetails
- type EdgeMetadata
- type EdgeRecord
- type EndpointMetadata
- type EndpointRecord
- type Envelope
- type IngestSummary
- type Metadata
- type OverlayApplication
- type Provenance
- type ServiceMetadata
- type ServiceRecord
- type SourceSummary
- type SupportSummary
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BuildSnapshotID ¶
func MarshalCanonical ¶
func TopologyDigest ¶
func TopologyDigest(mdl model.ResilienceModel) (string, error)
func WriteToFile ¶
Types ¶
type CoverageSummary ¶
type DiffSummary ¶
type DiffSummary struct {
AddedServices int `json:"added_services"`
RemovedServices int `json:"removed_services"`
ChangedServices int `json:"changed_services"`
AddedEdges int `json:"added_edges"`
RemovedEdges int `json:"removed_edges"`
ChangedEdges int `json:"changed_edges"`
AddedEndpoints int `json:"added_endpoints"`
RemovedEndpoints int `json:"removed_endpoints"`
ChangedEndpoints int `json:"changed_endpoints"`
}
func ComputeDiff ¶
func ComputeDiff(previous *Envelope, current Envelope) DiffSummary
type DiscoveryDetails ¶
type DiscoveryDetails struct {
Services []ServiceRecord `json:"services"`
Edges []EdgeRecord `json:"edges"`
Endpoints []EndpointRecord `json:"endpoints"`
Overlays []OverlayApplication `json:"overlays,omitempty"`
}
type EdgeMetadata ¶
type EdgeMetadata struct {
model.EdgeMetadata `json:",inline"`
Attributes map[string]string `json:"attributes,omitempty"`
}
func (EdgeMetadata) IsZero ¶ added in v0.3.0
func (m EdgeMetadata) IsZero() bool
func (*EdgeMetadata) Normalize ¶ added in v0.3.0
func (m *EdgeMetadata) Normalize()
type EdgeRecord ¶
type EdgeRecord struct {
ID string `json:"id"`
From string `json:"from"`
To string `json:"to"`
Kind model.EdgeKind `json:"kind"`
Blocking bool `json:"blocking"`
Support SupportSummary `json:"support"`
FirstSeen string `json:"first_seen,omitempty"`
LastSeen string `json:"last_seen,omitempty"`
Provenance []Provenance `json:"provenance,omitempty"`
Metadata *EdgeMetadata `json:"metadata,omitempty"`
Resilience *model.ResiliencePolicy `json:"resilience,omitempty"`
Observed *model.ObservedEdge `json:"observed,omitempty"`
PolicyScope *model.PolicyScope `json:"policy_scope,omitempty"`
}
type EndpointMetadata ¶
type EndpointMetadata struct {
model.EndpointMetadata `json:",inline"`
PredicateRef string `json:"predicate_ref,omitempty"`
Attributes map[string]string `json:"attributes,omitempty"`
}
func (EndpointMetadata) IsZero ¶ added in v0.3.0
func (m EndpointMetadata) IsZero() bool
func (*EndpointMetadata) Normalize ¶ added in v0.3.0
func (m *EndpointMetadata) Normalize()
type EndpointRecord ¶
type EndpointRecord struct {
ID string `json:"id"`
EntryService string `json:"entry_service"`
Method string `json:"method,omitempty"`
Path string `json:"path,omitempty"`
Support SupportSummary `json:"support"`
FirstSeen string `json:"first_seen,omitempty"`
LastSeen string `json:"last_seen,omitempty"`
Provenance []Provenance `json:"provenance,omitempty"`
Metadata *EndpointMetadata `json:"metadata,omitempty"`
}
type Envelope ¶
type Envelope struct {
SnapshotID string `json:"snapshot_id"`
TopologyVersion string `json:"topology_version"`
WindowStart string `json:"window_start"`
WindowEnd string `json:"window_end"`
Ingest IngestSummary `json:"ingest"`
Counts Counts `json:"counts"`
Coverage CoverageSummary `json:"coverage"`
Sources []SourceSummary `json:"sources"`
Diff DiffSummary `json:"diff"`
Discovery DiscoveryDetails `json:"discovery"`
Model model.ResilienceModel `json:"model"`
Metadata Metadata `json:"metadata"`
}
func (*Envelope) SortDeterministic ¶
func (e *Envelope) SortDeterministic()
func (Envelope) ValidateSemantic ¶
type IngestSummary ¶
type OverlayApplication ¶
type Provenance ¶
type ServiceMetadata ¶
type ServiceMetadata struct {
model.ServiceMetadata `json:",inline"`
ReplicasOverride *int `json:"replicas_override,omitempty"`
Attributes map[string]string `json:"attributes,omitempty"`
}
func (ServiceMetadata) IsZero ¶ added in v0.3.0
func (m ServiceMetadata) IsZero() bool
func (*ServiceMetadata) Normalize ¶ added in v0.3.0
func (m *ServiceMetadata) Normalize()
type ServiceRecord ¶
type ServiceRecord struct {
ID string `json:"id"`
Name string `json:"name"`
Replicas int `json:"replicas"`
Support SupportSummary `json:"support"`
FirstSeen string `json:"first_seen,omitempty"`
LastSeen string `json:"last_seen,omitempty"`
Provenance []Provenance `json:"provenance,omitempty"`
Metadata *ServiceMetadata `json:"metadata,omitempty"`
}
type SourceSummary ¶
type SupportSummary ¶
Click to show internal directories.
Click to hide internal directories.