Documentation ¶
Index ¶
- func ResourceTable() *schema.Resource
- func ValidateOnClusterEngine(inValue any, p hashicorpcty.Path) diag.Diagnostics
- func ValidatePartitionBy(inValue any, p hashicorpcty.Path) diag.Diagnostics
- func ValidateType(inValue any, p hashicorpcty.Path) diag.Diagnostics
- type CHColumn
- type CHTable
- type CHTableService
- func (ts *CHTableService) CreateTable(ctx context.Context, tableResource TableResource) error
- func (ts *CHTableService) DeleteTable(ctx context.Context, tableResource TableResource) error
- func (ts *CHTableService) GetDBTables(ctx context.Context, database string) ([]CHTable, error)
- func (ts *CHTableService) GetTable(ctx context.Context, database string, table string) (*CHTable, error)
- type ColumnDefinition
- type PartitionByResource
- type TableResource
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ResourceTable ¶
func ValidateOnClusterEngine ¶
func ValidateOnClusterEngine(inValue any, p hashicorpcty.Path) diag.Diagnostics
func ValidatePartitionBy ¶
func ValidatePartitionBy(inValue any, p hashicorpcty.Path) diag.Diagnostics
func ValidateType ¶
func ValidateType(inValue any, p hashicorpcty.Path) diag.Diagnostics
Types ¶
type CHTable ¶
type CHTable struct { Database string `ch:"database"` Name string `ch:"name"` EngineFull string `ch:"engine_full"` Engine string `ch:"engine"` Comment string `ch:"comment"` Columns []CHColumn `ch:"columns"` }
-- begin DB read() types --
func (*CHTable) ColumnsToResource ¶
func (t *CHTable) ColumnsToResource() []ColumnDefinition
func (*CHTable) ToResource ¶
func (t *CHTable) ToResource() (*TableResource, error)
type CHTableService ¶
func (*CHTableService) CreateTable ¶
func (ts *CHTableService) CreateTable(ctx context.Context, tableResource TableResource) error
func (*CHTableService) DeleteTable ¶
func (ts *CHTableService) DeleteTable(ctx context.Context, tableResource TableResource) error
func (*CHTableService) GetDBTables ¶
type ColumnDefinition ¶ added in v1.0.6
type PartitionByResource ¶
type TableResource ¶
type TableResource struct { Database string Name string EngineFull string Engine string Cluster string Comment string EngineParams []string OrderBy []string Columns []ColumnDefinition PartitionBy []PartitionByResource Settings map[string]string }
-- built from DB read, and from tf definition code --
func (*TableResource) GetColumnsResourceList ¶
func (t *TableResource) GetColumnsResourceList() []ColumnDefinition
func (*TableResource) HasColumn ¶
func (t *TableResource) HasColumn(columnName string) bool
func (*TableResource) SetPartitionBy ¶
func (t *TableResource) SetPartitionBy(partitionBy []interface{})
func (*TableResource) Validate ¶
func (t *TableResource) Validate(diags diag.Diagnostics)
Click to show internal directories.
Click to hide internal directories.