provider

package
v1.4.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 23, 2024 License: MPL-2.0 Imports: 29 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GenerateWorkspacePayload added in v1.2.0

func GenerateWorkspacePayload(plan workspace) map[string]interface{}

func GenerateWorkspaceState added in v1.2.0

func GenerateWorkspaceState(workspaceRead *WorkspaceRead) workspace

func New

func New(version string) func() provider.Provider

func SquaredUpAlertingChannelResource added in v1.2.0

func SquaredUpAlertingChannelResource() resource.Resource

func SquaredUpAlertingChannelTypes added in v1.2.0

func SquaredUpAlertingChannelTypes() datasource.DataSource

func SquaredUpDashboardResource

func SquaredUpDashboardResource() resource.Resource

func SquaredUpDashboardShareResource added in v1.2.0

func SquaredUpDashboardShareResource() resource.Resource

func SquaredUpDataStreams

func SquaredUpDataStreams() datasource.DataSource

func SquaredUpNodes added in v1.0.2

func SquaredUpNodes() datasource.DataSource

func SquaredUpScopeResource added in v1.4.0

func SquaredUpScopeResource() resource.Resource

func SquaredUpScriptResource added in v1.2.0

func SquaredUpScriptResource() resource.Resource

func SquaredupDataSourceResource

func SquaredupDataSourceResource() resource.Resource

func SquaredupDataSourcesDataSource

func SquaredupDataSourcesDataSource() datasource.DataSource

func SquaredupWorkspaceAlertResource added in v1.2.0

func SquaredupWorkspaceAlertResource() resource.Resource

func SquaredupWorkspaceResource

func SquaredupWorkspaceResource() resource.Resource

Types

type AlertChannel added in v1.2.0

type AlertChannel struct {
	ID                  string `json:"id"`
	IncludePreviewImage bool   `json:"includePreviewImage"`
}

type AlertConditions added in v1.2.0

type AlertConditions struct {
	Monitors AlertMonitors `json:"monitors"`
}

type AlertDashboard added in v1.2.0

type AlertDashboard struct {
	Tiles map[string]AlertTile `json:"tiles"`
}

type AlertMonitors added in v1.2.0

type AlertMonitors struct {
	IncludeAllTiles       bool                      `json:"includeAllTiles"`
	DashboardRollupHealth bool                      `json:"dashboardRollupHealth"`
	RollupHealth          bool                      `json:"rollupHealth"`
	Dashboards            map[string]AlertDashboard `json:"dashboards,omitempty"`
}

type AlertTile added in v1.2.0

type AlertTile struct {
	Include bool `json:"include"`
}

type AlertingChannel added in v1.2.0

type AlertingChannel struct {
	ID            string                 `json:"id"`
	DisplayName   string                 `json:"displayName"`
	Description   string                 `json:"description"`
	ChannelTypeID string                 `json:"channelTypeId"`
	Config        map[string]interface{} `json:"config"`
	Enabled       bool                   `json:"enabled"`
}

type AlertingChannelResource added in v1.2.0

type AlertingChannelResource struct {
	// contains filtered or unexported fields
}

func (*AlertingChannelResource) Configure added in v1.2.0

func (*AlertingChannelResource) Create added in v1.2.0

func (*AlertingChannelResource) Delete added in v1.2.0

func (*AlertingChannelResource) ImportState added in v1.2.0

func (*AlertingChannelResource) Metadata added in v1.2.0

func (*AlertingChannelResource) Read added in v1.2.0

func (*AlertingChannelResource) Schema added in v1.2.0

func (*AlertingChannelResource) Update added in v1.2.0

type AlertingChannelType added in v1.2.0

type AlertingChannelType struct {
	ChannelID             string `json:"id"`
	DisplayName           string `json:"displayName"`
	Protocol              string `json:"protocol"`
	ImagePreviewSupported bool   `json:"imagePreviewSupported"`
	Description           string `json:"description"`
}

type Dashboard

type Dashboard struct {
	DisplayName   string               `json:"displayName"`
	LastUpdated   string               `json:"lastUpdated"`
	WorkspaceID   string               `json:"workspaceId"`
	ID            string               `json:"id"`
	Content       jsontypes.Normalized `json:"content"`
	Name          string               `json:"name"`
	SchemaVersion string               `json:"schemaVersion"`
	Timeframe     string               `json:"timeframe,omitempty"`
}

type DashboardResource

type DashboardResource struct {
	// contains filtered or unexported fields
}

func (*DashboardResource) Configure

func (*DashboardResource) Create

func (*DashboardResource) Delete

func (*DashboardResource) ImportState

func (*DashboardResource) Metadata

func (*DashboardResource) Read

func (*DashboardResource) Schema

func (*DashboardResource) Update

type DashboardShare added in v1.2.0

type DashboardShare struct {
	LastUpdated string                   `json:"lastUpdated,omitempty"`
	ID          string                   `json:"id,omitempty"`
	TargetID    string                   `json:"targetId"`
	WorkspaceID string                   `json:"workspaceId"`
	Properties  DashboardShareProperties `json:"properties"`
}

type DashboardShareProperties added in v1.2.0

type DashboardShareProperties struct {
	Enabled               bool `json:"enabled"`
	RequireAuthentication bool `json:"requireAuthentication"`
}

type DashboardShareResource added in v1.2.0

type DashboardShareResource struct {
	// contains filtered or unexported fields
}

func (*DashboardShareResource) Configure added in v1.2.0

func (*DashboardShareResource) Create added in v1.2.0

func (*DashboardShareResource) Delete added in v1.2.0

func (*DashboardShareResource) ImportState added in v1.2.0

func (*DashboardShareResource) Metadata added in v1.2.0

func (*DashboardShareResource) Read added in v1.2.0

func (*DashboardShareResource) Schema added in v1.2.0

func (*DashboardShareResource) Update added in v1.2.0

type DashboardSharing added in v1.2.0

type DashboardSharing struct {
	DashboardShareID      types.String `tfsdk:"id"`
	DashboardID           types.String `tfsdk:"dashboard_id"`
	WorkspaceID           types.String `tfsdk:"workspace_id"`
	RequireAuthentication types.Bool   `tfsdk:"require_authentication"`
	EnableLink            types.Bool   `tfsdk:"enabled"`
	LastUpdated           types.String `tfsdk:"last_updated"`
}

type DataSource

type DataSource struct {
	DisplayName string `json:"displayName"`
	ID          string `json:"id,omitempty"`
	Plugin      struct {
		Name string `json:"name"`
	} `json:"plugin"`
	AgentGroupID string `json:"agentGroupId,omitempty"`
}

type DataSourceDataStreams

type DataSourceDataStreams struct {
	DisplayName    string `json:"displayName"`
	DataSourceName string `json:"dataSourceName"`
	ID             string `json:"id"`
	Definition     struct {
		Name string `json:"name"`
	} `json:"definition"`
}

type GremlinQueryResult added in v1.0.2

type GremlinQueryResult struct {
	ID          string   `json:"id"`
	SourceName  []string `json:"sourceName"`
	DisplayName []string `json:"name"`
	SourceID    []string `json:"sourceId"`
	Type        []string `json:"type"`
}

type LatestDataSource

type LatestDataSource struct {
	LambdaName  string `json:"lambdaName"`
	Version     string `json:"version"`
	OnPrem      bool   `json:"onPrem"`
	DisplayName string `json:"displayName"`
	PluginID    string `json:"id"`
}

type Scope added in v1.4.0

type Scope struct {
	Name        string                 `json:"name"`
	Version     int                    `json:"version"`
	Query       string                 `json:"query"`
	Bindings    map[string]interface{} `json:"bindings,omitempty"`
	QueryDetail ScopeQueryDetail       `json:"queryDetail"`
}

type ScopeCreate added in v1.4.0

type ScopeCreate struct {
	Scope Scope `json:"scope"`
}

type ScopeData added in v1.4.0

type ScopeData struct {
	ID          string `json:"id"`
	Query       string `json:"query"`
	QueryDetail string `json:"queryDetail"`
}

type ScopeQueryDetail added in v1.4.0

type ScopeQueryDetail struct {
	IDs          []string                 `json:"ids,omitempty"`
	Plugins      []ScopeQueryDetailPlugin `json:"plugins,omitempty"`
	Types        []ScopeQueryDetailType   `json:"types,omitempty"`
	BooleanQuery string                   `json:"booleanQuery,omitempty"`
}

type ScopeQueryDetailPlugin added in v1.4.0

type ScopeQueryDetailPlugin struct {
	Value string `json:"value,omitempty"`
}

type ScopeQueryDetailType added in v1.4.0

type ScopeQueryDetailType struct {
	Value string `json:"value,omitempty"`
}

type ScopeRead added in v1.4.0

type ScopeRead struct {
	ID          string    `json:"id"`
	DisplayName string    `json:"displayName"`
	Data        ScopeData `json:"data"`
	WorkspaceID string    `json:"workspaceId"`
}

type ScopeResource added in v1.4.0

type ScopeResource struct {
	// contains filtered or unexported fields
}

func (*ScopeResource) Configure added in v1.4.0

func (*ScopeResource) Create added in v1.4.0

func (*ScopeResource) Delete added in v1.4.0

func (*ScopeResource) ImportState added in v1.4.0

func (*ScopeResource) Metadata added in v1.4.0

func (*ScopeResource) Read added in v1.4.0

func (*ScopeResource) Schema added in v1.4.0

func (*ScopeResource) Update added in v1.4.0

type Script added in v1.2.0

type Script struct {
	DisplayName string       `json:"displayName"`
	ScriptType  string       `json:"scriptType,omitempty"`
	SubType     string       `json:"subType,omitempty"`
	Config      ScriptConfig `json:"config"`
	ID          string       `json:"id,omitempty"`
}

type ScriptConfig added in v1.2.0

type ScriptConfig struct {
	Src string `json:"src"`
}

type ScriptResource added in v1.2.0

type ScriptResource struct {
	// contains filtered or unexported fields
}

func (*ScriptResource) Configure added in v1.2.0

func (*ScriptResource) Create added in v1.2.0

func (*ScriptResource) Delete added in v1.2.0

func (*ScriptResource) ImportState added in v1.2.0

func (*ScriptResource) Metadata added in v1.2.0

func (*ScriptResource) Read added in v1.2.0

func (*ScriptResource) Schema added in v1.2.0

func (*ScriptResource) Update added in v1.2.0

type SelectedMonitors added in v1.2.0

type SelectedMonitors struct {
	DashboardID types.String   `tfsdk:"dashboard_id"`
	TilesID     []types.String `tfsdk:"tiles_id"`
}

type SquaredUpClient

type SquaredUpClient struct {
	// contains filtered or unexported fields
}

func NewSquaredUpClient

func NewSquaredUpClient(region string, apiKey string, version string) (*SquaredUpClient, error)

func (*SquaredUpClient) AddDataSource

func (c *SquaredUpClient) AddDataSource(displayName string, name string, pluginConfig map[string]interface{}, agentGroupId string) (*DataSource, error)

func (*SquaredUpClient) CreateAlertingChannel added in v1.2.0

func (c *SquaredUpClient) CreateAlertingChannel(alertChannel AlertingChannel) (*AlertingChannel, error)

func (*SquaredUpClient) CreateDashboard

func (c *SquaredUpClient) CreateDashboard(displayName string, workspaceId string, timeframe string, dashboardContent string) (*Dashboard, error)

func (*SquaredUpClient) CreateScope added in v1.4.0

func (c *SquaredUpClient) CreateScope(scope ScopeCreate, workspaceId string) (string, error)

func (*SquaredUpClient) CreateScript added in v1.2.0

func (c *SquaredUpClient) CreateScript(script Script) (*Script, error)

func (*SquaredUpClient) CreateSharedDashboard added in v1.2.0

func (c *SquaredUpClient) CreateSharedDashboard(dashboardShare DashboardShare) (*DashboardShare, error)

func (*SquaredUpClient) CreateWorkspace

func (c *SquaredUpClient) CreateWorkspace(workspacePayload map[string]interface{}) (string, error)

func (*SquaredUpClient) DeleteAlertingChannel added in v1.2.0

func (c *SquaredUpClient) DeleteAlertingChannel(alertChannelId string) error

func (*SquaredUpClient) DeleteDashboard

func (c *SquaredUpClient) DeleteDashboard(dashboardId string) error

func (*SquaredUpClient) DeleteDataSource

func (c *SquaredUpClient) DeleteDataSource(dataSourceId string) error

func (*SquaredUpClient) DeleteScope added in v1.4.0

func (c *SquaredUpClient) DeleteScope(scopeId string, workspaceId string) error

func (*SquaredUpClient) DeleteScript added in v1.2.0

func (c *SquaredUpClient) DeleteScript(scriptId string) error

func (*SquaredUpClient) DeleteSharedDashboard added in v1.2.0

func (c *SquaredUpClient) DeleteSharedDashboard(sharedDashboardId string) error

func (*SquaredUpClient) DeleteWorkspace

func (c *SquaredUpClient) DeleteWorkspace(workspaceId string) error

func (*SquaredUpClient) GenerateDataSourcePayload

func (c *SquaredUpClient) GenerateDataSourcePayload(displayName string, name string, pluginConfig map[string]interface{}, agentGroupId string) (map[string]interface{}, error)

func (*SquaredUpClient) GetAlertingChannel added in v1.2.0

func (c *SquaredUpClient) GetAlertingChannel(alertChannelId string) (*AlertingChannel, error)

func (*SquaredUpClient) GetAlertingChannelTypes added in v1.2.0

func (c *SquaredUpClient) GetAlertingChannelTypes(displayName string) ([]AlertingChannelType, error)

func (*SquaredUpClient) GetDashboard

func (c *SquaredUpClient) GetDashboard(dashboardId string) (*Dashboard, error)

func (*SquaredUpClient) GetDataSource

func (c *SquaredUpClient) GetDataSource(dataSourceId string) (*DataSource, error)

func (*SquaredUpClient) GetDataStreams

func (c *SquaredUpClient) GetDataStreams(dataSourceId string, DataStreamDefinitionName string) ([]DataSourceDataStreams, error)

func (*SquaredUpClient) GetLatestDataSources

func (c *SquaredUpClient) GetLatestDataSources(filterDisplayName string) ([]LatestDataSource, error)

func (*SquaredUpClient) GetNodes added in v1.0.2

func (c *SquaredUpClient) GetNodes(dataSourceId string, nodeName string, nodeSourceId string, allowNull bool) ([]GremlinQueryResult, error)

func (*SquaredUpClient) GetScope added in v1.4.0

func (c *SquaredUpClient) GetScope(scopeId string, workspaceId string) (*ScopeRead, error)

func (*SquaredUpClient) GetScript added in v1.2.0

func (c *SquaredUpClient) GetScript(scriptId string) (*Script, error)

func (*SquaredUpClient) GetSharedDashboard added in v1.2.0

func (c *SquaredUpClient) GetSharedDashboard(sharedDashboardId string) (*DashboardShare, error)

func (*SquaredUpClient) GetWorkspace

func (c *SquaredUpClient) GetWorkspace(workspaceId string) (*WorkspaceRead, error)

func (*SquaredUpClient) UpdateAlertingChannel added in v1.2.0

func (c *SquaredUpClient) UpdateAlertingChannel(alertChannelId string, alertChannel AlertingChannel) error

func (*SquaredUpClient) UpdateDashboard

func (c *SquaredUpClient) UpdateDashboard(dashboardId string, displayName string, timeframe string, dashboardContent string) (*Dashboard, error)

func (*SquaredUpClient) UpdateDataSource

func (c *SquaredUpClient) UpdateDataSource(dataSourceId string, displayName string, name string, pluginConfig map[string]interface{}, agentGroupId string) error

func (*SquaredUpClient) UpdateScope added in v1.4.0

func (c *SquaredUpClient) UpdateScope(scopeId string, scope ScopeCreate, workspaceId string) error

func (*SquaredUpClient) UpdateScript added in v1.2.0

func (c *SquaredUpClient) UpdateScript(scriptId string, script Script) error

func (*SquaredUpClient) UpdateSharedDashboard added in v1.2.0

func (c *SquaredUpClient) UpdateSharedDashboard(sharedDashboardId string, dashboardShare DashboardShare) error

func (*SquaredUpClient) UpdateWorkspace

func (c *SquaredUpClient) UpdateWorkspace(workspaceId string, workspacePayload map[string]interface{}) error

type SquaredUpScope added in v1.4.0

type SquaredUpScope struct {
	ScopeID       types.String   `tfsdk:"id"`
	DisplayName   types.String   `tfsdk:"display_name"`
	ScopeType     types.String   `tfsdk:"scope_type"`
	LastUpdated   types.String   `tfsdk:"last_updated"`
	WorkspaceId   types.String   `tfsdk:"workspace_id"`
	DataSourceId  []types.String `tfsdk:"data_source_id"`
	Types         []types.String `tfsdk:"types"`
	SearchQuery   types.String   `tfsdk:"search_query"`
	AdvancedQuery types.String   `tfsdk:"advanced_query"`
	NodeIds       []types.String `tfsdk:"node_ids"`
	Query         types.String   `tfsdk:"query"`
}

type SquaredupGremlinQuery added in v1.0.2

type SquaredupGremlinQuery struct {
	GremlinQueryResults []GremlinQueryResult `json:"gremlinQueryResults"`
}

type WorkspaceAlertData added in v1.2.0

type WorkspaceAlertData struct {
	Channels   []AlertChannel  `json:"channels"`
	Conditions AlertConditions `json:"conditions"`
}

type WorkspaceAlertsData added in v1.2.0

type WorkspaceAlertsData struct {
	AlertingRules []WorkspaceAlertData `json:"alertingRules"`
}
type WorkspaceLinks struct {
	Plugins    []string `json:"plugins"`
	Workspaces []string `json:"workspaces"`
}

type WorkspaceProperties

type WorkspaceProperties struct {
	DashboardSharingEnabled bool     `json:"openAccessEnabled"`
	Tags                    []string `json:"tags"`
	Description             string   `json:"description"`
	Type                    string   `json:"type,omitempty"`
}

type WorkspaceRead

type WorkspaceRead struct {
	ID          string            `json:"id"`
	DisplayName string            `json:"displayName"`
	Data        WorkspaceReadData `json:"data"`
}

type WorkspaceReadData

type WorkspaceReadData struct {
	AlertingRules []WorkspaceAlertData `json:"alertingRules,omitempty"`
	LinkedObjects string               `json:"linkedObjects"`
	Properties    WorkspaceProperties  `json:"properties"`
	Links         WorkspaceLinks       `json:"links"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL