Documentation ¶
Overview ¶
Package model provides functions to convert models to GraphQL models
Index ¶
- Variables
- func ClearCurrentAgentUpgradeError(cur *model.Agent)
- type AgentChange
- type AgentChangeType
- type AgentConfiguration
- type Agents
- type ClearAgentUpgradeErrorInput
- type ConfigurationChange
- type Configurations
- type DestinationWithType
- type EventType
- type GraphMetric
- type GraphMetrics
- type OverviewPage
- type ParameterType
- type RelevantIfOperatorType
- type RemoveAgentConfigurationInput
- type ResourceTypeKind
- type Snapshot
- type UpdateProcessorsInput
Constants ¶
This section is empty.
Variables ¶
View Source
var AllAgentChangeType = []AgentChangeType{ AgentChangeTypeInsert, AgentChangeTypeUpdate, AgentChangeTypeRemove, }
View Source
var AllEventType = []EventType{ EventTypeInsert, EventTypeUpdate, EventTypeRemove, }
View Source
var AllParameterType = []ParameterType{ ParameterTypeString, ParameterTypeStrings, ParameterTypeInt, ParameterTypeBool, ParameterTypeEnum, ParameterTypeEnums, ParameterTypeMap, ParameterTypeYaml, ParameterTypeTimezone, ParameterTypeMetrics, ParameterTypeAwsCloudwatchNamedField, }
View Source
var AllRelevantIfOperatorType = []RelevantIfOperatorType{ RelevantIfOperatorTypeEquals, RelevantIfOperatorTypeNotEquals, RelevantIfOperatorTypeContainsAny, }
View Source
var AllResourceTypeKind = []ResourceTypeKind{ ResourceTypeKindSource, ResourceTypeKindDestination, }
Functions ¶
func ClearCurrentAgentUpgradeError ¶ added in v1.10.0
ClearCurrentAgentUpgradeError clears the current agent upgrade error
Types ¶
type AgentChange ¶
type AgentChange struct { Agent *model.Agent `json:"agent"` ChangeType AgentChangeType `json:"changeType"` }
func ToAgentChange ¶
func ToAgentChange(change store.Event[*model.Agent]) *AgentChange
ToAgentChange converts a store.AgentChange to use for use with graphql
func ToAgentChangeArray ¶
func ToAgentChangeArray(changes store.Events[*model.Agent]) []*AgentChange
ToAgentChangeArray converts store.AgentChanges to a []*AgentChange for use with graphql
type AgentChangeType ¶
type AgentChangeType string
const ( AgentChangeTypeInsert AgentChangeType = "INSERT" AgentChangeTypeUpdate AgentChangeType = "UPDATE" AgentChangeTypeRemove AgentChangeType = "REMOVE" )
func (AgentChangeType) IsValid ¶
func (e AgentChangeType) IsValid() bool
func (AgentChangeType) MarshalGQL ¶
func (e AgentChangeType) MarshalGQL(w io.Writer)
func (AgentChangeType) String ¶
func (e AgentChangeType) String() string
func (*AgentChangeType) UnmarshalGQL ¶
func (e *AgentChangeType) UnmarshalGQL(v interface{}) error
type AgentConfiguration ¶
type ClearAgentUpgradeErrorInput ¶ added in v1.10.0
type ClearAgentUpgradeErrorInput struct {
AgentID string `json:"agentId"`
}
type ConfigurationChange ¶
type ConfigurationChange struct { Configuration *model.Configuration `json:"configuration"` EventType EventType `json:"eventType"` }
func ToConfigurationChange ¶
func ToConfigurationChange(event store.Event[*model.Configuration]) *ConfigurationChange
ToConfigurationChange converts a store.Event for Configuration to a ConfigurationChange for use with graphql
func ToConfigurationChanges ¶
func ToConfigurationChanges(events store.Events[*model.Configuration]) []*ConfigurationChange
ToConfigurationChanges converts store.Events for Configuration to an array of ConfigurationChange for use with graphql
type Configurations ¶
type Configurations struct { Query *string `json:"query"` Configurations []*model.Configuration `json:"configurations"` Suggestions []*search.Suggestion `json:"suggestions"` }
type DestinationWithType ¶
type DestinationWithType struct { Destination *model.Destination `json:"destination"` DestinationType *model.DestinationType `json:"destinationType"` }
type EventType ¶
type EventType string
func ToEventType ¶
ToEventType converts a store.EventType to a graphql EventType
func (EventType) MarshalGQL ¶
func (*EventType) UnmarshalGQL ¶
type GraphMetric ¶ added in v1.3.0
type GraphMetric struct { Name string `json:"name"` NodeID string `json:"nodeID"` PipelineType string `json:"pipelineType"` Value float64 `json:"value"` Unit string `json:"unit"` AgentID *string `json:"agentID"` }
func ToGraphMetric ¶ added in v1.3.0
func ToGraphMetric(m *record.Metric) (*GraphMetric, error)
ToGraphMetric converts a Metric to a GraphMetric
type GraphMetrics ¶ added in v1.3.0
type GraphMetrics struct {
Metrics []*GraphMetric `json:"metrics"`
}
type OverviewPage ¶ added in v1.3.0
type ParameterType ¶
type ParameterType string
const ( ParameterTypeString ParameterType = "string" ParameterTypeStrings ParameterType = "strings" ParameterTypeInt ParameterType = "int" ParameterTypeBool ParameterType = "bool" ParameterTypeEnum ParameterType = "enum" ParameterTypeEnums ParameterType = "enums" ParameterTypeMap ParameterType = "map" ParameterTypeYaml ParameterType = "yaml" ParameterTypeTimezone ParameterType = "timezone" ParameterTypeMetrics ParameterType = "metrics" ParameterTypeAwsCloudwatchNamedField ParameterType = "awsCloudwatchNamedField" )
func (ParameterType) IsValid ¶
func (e ParameterType) IsValid() bool
func (ParameterType) MarshalGQL ¶
func (e ParameterType) MarshalGQL(w io.Writer)
func (ParameterType) String ¶
func (e ParameterType) String() string
func (*ParameterType) UnmarshalGQL ¶
func (e *ParameterType) UnmarshalGQL(v interface{}) error
type RelevantIfOperatorType ¶
type RelevantIfOperatorType string
const ( RelevantIfOperatorTypeEquals RelevantIfOperatorType = "equals" RelevantIfOperatorTypeNotEquals RelevantIfOperatorType = "notEquals" RelevantIfOperatorTypeContainsAny RelevantIfOperatorType = "containsAny" )
func (RelevantIfOperatorType) IsValid ¶
func (e RelevantIfOperatorType) IsValid() bool
func (RelevantIfOperatorType) MarshalGQL ¶
func (e RelevantIfOperatorType) MarshalGQL(w io.Writer)
func (RelevantIfOperatorType) String ¶
func (e RelevantIfOperatorType) String() string
func (*RelevantIfOperatorType) UnmarshalGQL ¶
func (e *RelevantIfOperatorType) UnmarshalGQL(v interface{}) error
type RemoveAgentConfigurationInput ¶ added in v1.9.0
type RemoveAgentConfigurationInput struct {
AgentID string `json:"agentId"`
}
type ResourceTypeKind ¶ added in v1.7.0
type ResourceTypeKind string
const ( ResourceTypeKindSource ResourceTypeKind = "SOURCE" ResourceTypeKindDestination ResourceTypeKind = "DESTINATION" )
func (ResourceTypeKind) IsValid ¶ added in v1.7.0
func (e ResourceTypeKind) IsValid() bool
func (ResourceTypeKind) MarshalGQL ¶ added in v1.7.0
func (e ResourceTypeKind) MarshalGQL(w io.Writer)
func (ResourceTypeKind) String ¶ added in v1.7.0
func (e ResourceTypeKind) String() string
func (*ResourceTypeKind) UnmarshalGQL ¶ added in v1.7.0
func (e *ResourceTypeKind) UnmarshalGQL(v interface{}) error
type UpdateProcessorsInput ¶ added in v1.7.0
type UpdateProcessorsInput struct { Configuration string `json:"configuration"` ResourceType ResourceTypeKind `json:"resourceType"` ResourceIndex int `json:"resourceIndex"` Processors []*model.ResourceConfiguration `json:"processors"` }
Click to show internal directories.
Click to hide internal directories.