Documentation ¶
Index ¶
- Variables
- func ResolveResourceAndArgsFromSQLString[T modconfig.ModTreeItem](sqlString string, w *workspace.Workspace) (modconfig.ModTreeItem, *resources.QueryArgs, error)
- func SqlLooksLikeExecutableResource(input string) (string, bool)
- type LoadPowerpipeWorkspaceConfig
- type LoadPowerpipeWorkspaceOption
- func WithBlockType(blockTypeInclusions []string) LoadPowerpipeWorkspaceOption
- func WithLateBinding(enabled bool) LoadPowerpipeWorkspaceOption
- func WithPipelingConnections(pipelingConnections map[string]connection.PipelingConnection) LoadPowerpipeWorkspaceOption
- func WithSkipResourceLoadIfNoModfile(enabled bool) LoadPowerpipeWorkspaceOption
- func WithVariableValidation(enabled bool) LoadPowerpipeWorkspaceOption
- type PowerpipeWorkspace
- func Load(ctx context.Context, workspacePath string, ...) (w *PowerpipeWorkspace, ew error_helpers.ErrorAndWarnings)
- func LoadWorkspacePromptingForVariables(ctx context.Context, workspacePath string, ...) (*PowerpipeWorkspace, error_helpers.ErrorAndWarnings)
- func NewPowerpipeWorkspace(workspacePath string) *PowerpipeWorkspace
- func (w *PowerpipeWorkspace) Close()
- func (w *PowerpipeWorkspace) GetPowerpipeModResources() *resources.PowerpipeModResources
- func (w *PowerpipeWorkspace) GetQueryProvider(queryName string) (resources.QueryProvider, bool)
- func (w *PowerpipeWorkspace) PublishDashboardEvent(ctx context.Context, e dashboardevents.DashboardEvent)
- func (w *PowerpipeWorkspace) RegisterDashboardEventHandler(ctx context.Context, handler dashboardevents.DashboardEventHandler)
- func (w *PowerpipeWorkspace) ResolveQueryFromQueryProvider(queryProvider resources.QueryProvider, runtimeArgs *resources.QueryArgs) (*modconfig.ResolvedQuery, error)
- func (w *PowerpipeWorkspace) UnregisterDashboardEventHandlers()
Constants ¶
This section is empty.
Variables ¶
View Source
var EventCount int64 = 0
Functions ¶
func ResolveResourceAndArgsFromSQLString ¶
func ResolveResourceAndArgsFromSQLString[T modconfig.ModTreeItem](sqlString string, w *workspace.Workspace) (modconfig.ModTreeItem, *resources.QueryArgs, error)
ResolveResourceAndArgsFromSQLString attempts to resolve 'arg' to a resource of type T and (optionally) query args
Types ¶
type LoadPowerpipeWorkspaceConfig ¶
type LoadPowerpipeWorkspaceConfig struct {
// contains filtered or unexported fields
}
type LoadPowerpipeWorkspaceOption ¶
type LoadPowerpipeWorkspaceOption func(*LoadPowerpipeWorkspaceConfig)
func WithBlockType ¶
func WithBlockType(blockTypeInclusions []string) LoadPowerpipeWorkspaceOption
func WithLateBinding ¶
func WithLateBinding(enabled bool) LoadPowerpipeWorkspaceOption
func WithPipelingConnections ¶
func WithPipelingConnections(pipelingConnections map[string]connection.PipelingConnection) LoadPowerpipeWorkspaceOption
func WithSkipResourceLoadIfNoModfile ¶
func WithSkipResourceLoadIfNoModfile(enabled bool) LoadPowerpipeWorkspaceOption
TODO this is only needed as Pipe fittings tests rely on loading workspaces without modfiles
func WithVariableValidation ¶
func WithVariableValidation(enabled bool) LoadPowerpipeWorkspaceOption
type PowerpipeWorkspace ¶
func Load ¶
func Load(ctx context.Context, workspacePath string, opts ...LoadPowerpipeWorkspaceOption) (w *PowerpipeWorkspace, ew error_helpers.ErrorAndWarnings)
func LoadWorkspacePromptingForVariables ¶
func LoadWorkspacePromptingForVariables(ctx context.Context, workspacePath string, opts ...LoadPowerpipeWorkspaceOption) (*PowerpipeWorkspace, error_helpers.ErrorAndWarnings)
func NewPowerpipeWorkspace ¶
func NewPowerpipeWorkspace(workspacePath string) *PowerpipeWorkspace
func (*PowerpipeWorkspace) Close ¶
func (w *PowerpipeWorkspace) Close()
func (*PowerpipeWorkspace) GetPowerpipeModResources ¶
func (w *PowerpipeWorkspace) GetPowerpipeModResources() *resources.PowerpipeModResources
GetPowerpipeModResources returns the powerpipe PowerpipeModResources from the workspace, cast to the correct type
func (*PowerpipeWorkspace) GetQueryProvider ¶
func (w *PowerpipeWorkspace) GetQueryProvider(queryName string) (resources.QueryProvider, bool)
func (*PowerpipeWorkspace) PublishDashboardEvent ¶
func (w *PowerpipeWorkspace) PublishDashboardEvent(ctx context.Context, e dashboardevents.DashboardEvent)
func (*PowerpipeWorkspace) RegisterDashboardEventHandler ¶
func (w *PowerpipeWorkspace) RegisterDashboardEventHandler(ctx context.Context, handler dashboardevents.DashboardEventHandler)
RegisterDashboardEventHandler starts the event handler goroutine if necessary and adds the event handler to our list
func (*PowerpipeWorkspace) ResolveQueryFromQueryProvider ¶
func (w *PowerpipeWorkspace) ResolveQueryFromQueryProvider(queryProvider resources.QueryProvider, runtimeArgs *resources.QueryArgs) (*modconfig.ResolvedQuery, error)
ResolveQueryFromQueryProvider resolves the query for the given QueryProvider
func (*PowerpipeWorkspace) UnregisterDashboardEventHandlers ¶
func (w *PowerpipeWorkspace) UnregisterDashboardEventHandlers()
UnregisterDashboardEventHandlers clears all event handlers used when generating multiple snapshots
Click to show internal directories.
Click to hide internal directories.