Documentation
¶
Index ¶
- Variables
- func DataSourceWarehouse() common.Resource
- func DataSourceWarehouses() common.Resource
- func NewSqlGlobalConfigAPI(ctx context.Context, m any) globalConfigAPI
- func ResourceSqlAlert() common.Resource
- func ResourceSqlDashboard() common.Resource
- func ResourceSqlEndpoint() common.Resource
- func ResourceSqlGlobalConfig() common.Resource
- func ResourceSqlQuery() common.Resource
- func ResourceSqlVisualization() common.Resource
- func ResourceSqlWidget() common.Resource
- type AlertEntity
- type AlertOptions
- type DashboardAPI
- type DashboardEntity
- type GlobalConfig
- type GlobalConfigForRead
- type QueryAPI
- type QueryEntity
- type QueryParameter
- type QueryParameterAllowMultiple
- type QueryParameterDateLike
- type QueryParameterDateRangeLike
- type QueryParameterEnum
- type QueryParameterNumber
- type QueryParameterQuery
- type QueryParameterText
- type QuerySchedule
- type QueryScheduleContinuous
- type QueryScheduleDaily
- type QueryScheduleWeekly
- type SqlWarehouse
- type VisualizationAPI
- func (a VisualizationAPI) Create(v *api.Visualization) error
- func (a VisualizationAPI) Delete(visualizationID string) error
- func (a VisualizationAPI) Read(queryID, visualizationID string) (*api.Visualization, error)
- func (a VisualizationAPI) Update(visualizationID string, v *api.Visualization) error
- type VisualizationEntity
- type WidgetAPI
- type WidgetEntity
- type WidgetParameter
- type WidgetPosition
Constants ¶
This section is empty.
Variables ¶
var ( ClusterSizes = []string{"2X-Small", "X-Small", "Small", "Medium", "Large", "X-Large", "2X-Large", "3X-Large", "4X-Large"} MaxNumClusters = 30 )
ClusterSizes for SQL endpoints
var (
GlobalSqlConfigResourceID = "global"
)
Functions ¶
func DataSourceWarehouse ¶ added in v1.1.0
func DataSourceWarehouses ¶ added in v1.1.0
func NewSqlGlobalConfigAPI ¶
func ResourceSqlAlert ¶ added in v1.13.0
func ResourceSqlDashboard ¶
func ResourceSqlEndpoint ¶
func ResourceSqlGlobalConfig ¶
func ResourceSqlQuery ¶
func ResourceSqlWidget ¶
Types ¶
type AlertEntity ¶ added in v1.13.0
type AlertEntity struct {
Name string `json:"name"`
QueryId string `json:"query_id"`
Rearm int `json:"rearm,omitempty"`
Options *AlertOptions `json:"options"`
Parent string `json:"parent,omitempty" tf:"suppress_diff,force_new"`
CreatedAt string `json:"created_at,omitempty" tf:"computed"`
UpdatedAt string `json:"updated_at,omitempty" tf:"computed"`
}
type AlertOptions ¶ added in v1.13.0
type AlertOptions struct {
Column string `json:"column"`
Op string `json:"op"`
Value string `json:"value"`
Muted bool `json:"muted,omitempty"`
CustomBody string `json:"custom_body,omitempty"`
CustomSubject string `json:"custom_subject,omitempty"`
EmptyResultState string `json:"empty_result_state,omitempty"`
}
type DashboardAPI ¶
type DashboardAPI struct {
// contains filtered or unexported fields
}
DashboardAPI ...
func NewDashboardAPI ¶
func NewDashboardAPI(ctx context.Context, m any) DashboardAPI
NewDashboardAPI ...
type DashboardEntity ¶
type DashboardEntity struct {
Name string `json:"name"`
Tags []string `json:"tags,omitempty"`
Parent string `json:"parent,omitempty" tf:"suppress_diff,force_new"`
CreatedAt string `json:"created_at,omitempty" tf:"computed"`
UpdatedAt string `json:"updated_at,omitempty" tf:"computed"`
RunAsRole string `json:"run_as_role,omitempty" tf:"suppress_diff"`
DashboardFiltersEnabled bool `json:"dashboard_filters_enabled,omitempty"`
}
DashboardEntity defines the parameters that can be set in the resource.
type GlobalConfig ¶
type GlobalConfig struct {
SecurityPolicy string `json:"security_policy,omitempty" tf:"default:DATA_ACCESS_CONTROL"`
DataAccessConfig map[string]string `json:"data_access_config,omitempty"`
InstanceProfileARN string `json:"instance_profile_arn,omitempty"`
GoogleServiceAccount string `json:"google_service_account,omitempty"`
EnableServerlessCompute bool `json:"enable_serverless_compute,omitempty" tf:"default:false"`
SqlConfigParams map[string]string `json:"sql_config_params,omitempty"`
}
GlobalConfig used to generate Terraform resource schema and bind to resource data
type GlobalConfigForRead ¶
type GlobalConfigForRead struct {
SecurityPolicy string `json:"security_policy"`
DataAccessConfig []confPair `json:"data_access_config"`
InstanceProfileARN string `json:"instance_profile_arn,omitempty"`
GoogleServiceAccount string `json:"google_service_account,omitempty"`
EnableServerlessCompute bool `json:"enable_serverless_compute"`
SqlConfigurationParameters *repeatedEndpointConfPairs `json:"sql_configuration_parameters,omitempty"`
}
GlobalConfigForRead used to talk to REST API
type QueryEntity ¶
type QueryEntity struct {
DataSourceID string `json:"data_source_id"`
Name string `json:"name"`
Description string `json:"description,omitempty"`
Query string `json:"query"`
// Deprecated: Use databricks_job resource to schedule a Query
Schedule *QuerySchedule `json:"schedule,omitempty"`
Tags []string `json:"tags,omitempty"`
Parameter []QueryParameter `json:"parameter,omitempty"`
RunAsRole string `json:"run_as_role,omitempty" tf:"suppress_diff"`
Parent string `json:"parent,omitempty" tf:"suppress_diff,force_new"`
CreatedAt string `json:"created_at,omitempty" tf:"computed"`
UpdatedAt string `json:"updated_at,omitempty" tf:"computed"`
}
QueryEntity defines the parameters that can be set in the resource.
type QueryParameter ¶
type QueryParameter struct {
Name string `json:"name"`
Title string `json:"title,omitempty"`
// Type specific structs.
// Only one of them may be set.
Text *QueryParameterText `json:"text,omitempty"`
Number *QueryParameterNumber `json:"number,omitempty"`
Enum *QueryParameterEnum `json:"enum,omitempty"`
Query *QueryParameterQuery `json:"query,omitempty"`
Date *QueryParameterDateLike `json:"date,omitempty"`
DateTime *QueryParameterDateLike `json:"datetime,omitempty"`
DateTimeSec *QueryParameterDateLike `json:"datetimesec,omitempty"`
DateRange *QueryParameterDateRangeLike `json:"date_range,omitempty"`
DateTimeRange *QueryParameterDateRangeLike `json:"datetime_range,omitempty"`
DateTimeSecRange *QueryParameterDateRangeLike `json:"datetimesec_range,omitempty"`
}
QueryParameter ...
type QueryParameterAllowMultiple ¶
type QueryParameterAllowMultiple struct {
Prefix string `json:"prefix,omitempty"`
Suffix string `json:"suffix,omitempty"`
Separator string `json:"separator"`
}
QueryParameterAllowMultiple ...
type QueryParameterDateLike ¶
type QueryParameterDateLike struct {
Value string `json:"value"`
}
QueryParameterDateLike ...
type QueryParameterDateRangeLike ¶
type QueryParameterDateRangeLike struct {
Value string `json:"value,omitempty"`
Range *api.DateTimeRange `json:"range,omitempty"`
}
QueryParameterDateRangeLike ...
type QueryParameterEnum ¶
type QueryParameterEnum struct {
// Value iff `multiple == nil`
Value string `json:"value,omitempty"`
// Values iff `multiple != nil`
Values []string `json:"values,omitempty"`
Options []string `json:"options"`
Multiple *QueryParameterAllowMultiple `json:"multiple,omitempty"`
}
QueryParameterEnum ...
type QueryParameterNumber ¶
type QueryParameterNumber struct {
Value float64 `json:"value"`
}
QueryParameterNumber ...
type QueryParameterQuery ¶
type QueryParameterQuery struct {
// Value iff `multiple == nil`
Value string `json:"value,omitempty"`
// Values iff `multiple != nil`
Values []string `json:"values,omitempty"`
QueryID string `json:"query_id"`
Multiple *QueryParameterAllowMultiple `json:"multiple,omitempty"`
}
QueryParameterQuery ...
type QueryParameterText ¶
type QueryParameterText struct {
Value string `json:"value"`
}
QueryParameterText ...
type QuerySchedule ¶
type QuerySchedule struct {
Continuous *QueryScheduleContinuous `json:"continuous,omitempty"`
Daily *QueryScheduleDaily `json:"daily,omitempty"`
Weekly *QueryScheduleWeekly `json:"weekly,omitempty"`
}
QuerySchedule ... Deprecated: Use databricks_job resource to schedule a Query
type QueryScheduleContinuous ¶
type QueryScheduleContinuous struct {
IntervalSeconds int `json:"interval_seconds"`
UntilDate string `json:"until_date,omitempty"`
}
QueryScheduleContinuous ... Deprecated: Use databricks_job resource to schedule a Query
type QueryScheduleDaily ¶
type QueryScheduleDaily struct {
IntervalDays int `json:"interval_days"`
TimeOfDay string `json:"time_of_day"`
UntilDate string `json:"until_date,omitempty"`
}
QueryScheduleDaily ... Deprecated: Use databricks_job resource to schedule a Query
type QueryScheduleWeekly ¶
type QueryScheduleWeekly struct {
IntervalWeeks int `json:"interval_weeks"`
DayOfWeek string `json:"day_of_week"`
TimeOfDay string `json:"time_of_day"`
UntilDate string `json:"until_date,omitempty"`
}
QueryScheduleWeekly ... Deprecated: Use databricks_job resource to schedule a Query
type SqlWarehouse ¶ added in v1.34.0
type SqlWarehouse struct {
sql.GetWarehouseResponse
// The data source ID is not part of the endpoint API response.
// We manually resolve it by retrieving the list of data sources
// and matching this entity's endpoint ID.
DataSourceId string `json:"data_source_id,omitempty" tf:"computed"`
}
type VisualizationAPI ¶
type VisualizationAPI struct {
// contains filtered or unexported fields
}
VisualizationAPI ...
func NewVisualizationAPI ¶
func NewVisualizationAPI(ctx context.Context, m any) VisualizationAPI
NewVisualizationAPI ...
func (VisualizationAPI) Create ¶
func (a VisualizationAPI) Create(v *api.Visualization) error
Create ...
func (VisualizationAPI) Delete ¶
func (a VisualizationAPI) Delete(visualizationID string) error
Delete ...
func (VisualizationAPI) Read ¶
func (a VisualizationAPI) Read(queryID, visualizationID string) (*api.Visualization, error)
Read ...
func (VisualizationAPI) Update ¶
func (a VisualizationAPI) Update(visualizationID string, v *api.Visualization) error
Update ...
type VisualizationEntity ¶
type VisualizationEntity struct {
QueryID string `json:"query_id" tf:"force_new"`
VisualizationID string `json:"visualization_id,omitempty" tf:"computed,force_new"`
Type string `json:"type"`
Name string `json:"name"`
Description string `json:"description,omitempty"`
Options string `json:"options"`
QueryPlan string `json:"query_plan,omitempty"`
}
VisualizationEntity defines the parameters that can be set in the resource.
type WidgetAPI ¶
type WidgetAPI struct {
// contains filtered or unexported fields
}
WidgetAPI ...
type WidgetEntity ¶
type WidgetEntity struct {
DashboardID string `json:"dashboard_id" tf:"force_new"`
WidgetID string `json:"widget_id,omitempty" tf:"computed,force_new"`
Title string `json:"title,omitempty"`
Description string `json:"description,omitempty"`
Text string `json:"text,omitempty"`
VisualizationID string `json:"visualization_id,omitempty" tf:"force_new"`
Position *WidgetPosition `json:"position,omitempty"`
Parameter []WidgetParameter `json:"parameter,omitempty" tf:"slice_set"`
}
WidgetEntity defines the parameters that can be set in the resource.
type WidgetParameter ¶
type WidgetParameter struct {
Name string `json:"name"`
Type string `json:"type"`
MapTo string `json:"map_to,omitempty"`
Title string `json:"title,omitempty"`
// Mutually exclusive.
Value string `json:"value,omitempty"`
Values []string `json:"values,omitempty"`
}
WidgetParameter ...