Documentation
      ¶
    
    
  
    
  
    Index ¶
- Constants
 - Variables
 - func ConvertOptionsToTF(ctx context.Context, options *admin.StreamsOptions) (*types.Object, diag.Diagnostics)
 - func DataSource() datasource.DataSource
 - func NewStreamProcessorReq(ctx context.Context, plan *TFStreamProcessorRSModel) (*admin.StreamsProcessor, diag.Diagnostics)
 - func PluralDataSource() datasource.DataSource
 - func Resource() resource.Resource
 - func ResourceSchema(ctx context.Context) schema.Schema
 - func WaitStateTransition(ctx context.Context, requestParams *admin.GetStreamProcessorApiParams, ...) (*admin.StreamsProcessorWithStats, error)
 - type StreamProccesorDS
 - type TFDlqModel
 - type TFOptionsModel
 - type TFStreamProcessorDSModel
 - type TFStreamProcessorRSModel
 - type TFStreamProcessorsDSModel
 
Constants ¶
      View Source
      
  
    const ( InitiatingState = "INIT" CreatingState = "CREATING" CreatedState = "CREATED" StartedState = "STARTED" StoppedState = "STOPPED" DroppedState = "DROPPED" FailedState = "FAILED" )
      View Source
      
  
const StreamProcessorName = "stream_processor"
    Variables ¶
      View Source
      
  
    var DlqObjectType = types.ObjectType{AttrTypes: map[string]attr.Type{ "coll": types.StringType, "connection_name": types.StringType, "db": types.StringType, }, }
      View Source
      
  
var OptionsObjectType = types.ObjectType{AttrTypes: map[string]attr.Type{ "dlq": DlqObjectType, }}
Functions ¶
func ConvertOptionsToTF ¶
func ConvertOptionsToTF(ctx context.Context, options *admin.StreamsOptions) (*types.Object, diag.Diagnostics)
func DataSource ¶
func DataSource() datasource.DataSource
func NewStreamProcessorReq ¶
func NewStreamProcessorReq(ctx context.Context, plan *TFStreamProcessorRSModel) (*admin.StreamsProcessor, diag.Diagnostics)
func PluralDataSource ¶
func PluralDataSource() datasource.DataSource
func WaitStateTransition ¶
func WaitStateTransition(ctx context.Context, requestParams *admin.GetStreamProcessorApiParams, client admin.StreamsApi, pendingStates, desiredStates []string) (*admin.StreamsProcessorWithStats, error)
Types ¶
type StreamProccesorDS ¶
func (*StreamProccesorDS) Read ¶
func (d *StreamProccesorDS) Read(ctx context.Context, req datasource.ReadRequest, resp *datasource.ReadResponse)
func (*StreamProccesorDS) Schema ¶
func (d *StreamProccesorDS) Schema(ctx context.Context, req datasource.SchemaRequest, resp *datasource.SchemaResponse)
type TFDlqModel ¶
type TFOptionsModel ¶
type TFStreamProcessorDSModel ¶
type TFStreamProcessorDSModel struct {
	ID            types.String `tfsdk:"id"`
	InstanceName  types.String `tfsdk:"instance_name"`
	Options       types.Object `tfsdk:"options"`
	Pipeline      types.String `tfsdk:"pipeline"`
	ProcessorName types.String `tfsdk:"processor_name"`
	ProjectID     types.String `tfsdk:"project_id"`
	State         types.String `tfsdk:"state"`
	Stats         types.String `tfsdk:"stats"`
}
    func NewTFStreamprocessorDSModel ¶
func NewTFStreamprocessorDSModel(ctx context.Context, projectID, instanceName string, apiResp *admin.StreamsProcessorWithStats) (*TFStreamProcessorDSModel, diag.Diagnostics)
type TFStreamProcessorRSModel ¶
type TFStreamProcessorRSModel struct {
	InstanceName  types.String       `tfsdk:"instance_name"`
	Options       types.Object       `tfsdk:"options"`
	Pipeline      fwtypes.JSONString `tfsdk:"pipeline"`
	ProcessorID   types.String       `tfsdk:"id"`
	ProcessorName types.String       `tfsdk:"processor_name"`
	ProjectID     types.String       `tfsdk:"project_id"`
	State         types.String       `tfsdk:"state"`
	Stats         types.String       `tfsdk:"stats"`
}
    func NewStreamProcessorWithStats ¶
func NewStreamProcessorWithStats(ctx context.Context, projectID, instanceName string, apiResp *admin.StreamsProcessorWithStats) (*TFStreamProcessorRSModel, diag.Diagnostics)
type TFStreamProcessorsDSModel ¶
type TFStreamProcessorsDSModel struct {
	ProjectID    types.String               `tfsdk:"project_id"`
	InstanceName types.String               `tfsdk:"instance_name"`
	Results      []TFStreamProcessorDSModel `tfsdk:"results"`
}
    func NewTFStreamProcessors ¶
func NewTFStreamProcessors(ctx context.Context, streamProcessorsConfig *TFStreamProcessorsDSModel, sdkResults []admin.StreamsProcessorWithStats) (*TFStreamProcessorsDSModel, diag.Diagnostics)
 Click to show internal directories. 
   Click to hide internal directories.