plugin_manager

package
v0.1.0-alpha.202412121623 Latest Latest
Warning

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

Go to latest
Published: Dec 12, 2024 License: AGPL-3.0 Imports: 23 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CollectResponse

type CollectResponse struct {
	ExecutionId string
	Schema      *schema.RowSchema
}

func CollectResponseFromProto

func CollectResponseFromProto(resp *proto.CollectResponse) *CollectResponse

type DescribeResponse

type DescribeResponse struct {
	TableSchemas schema.SchemaMap             `json:"tables"`
	Sources      row_source.SourceMetadataMap `json:"sources"`
}

func DescribeResponseFromProto

func DescribeResponseFromProto(resp *proto.DescribeResponse) *DescribeResponse

type Observer

type Observer interface {
	Notify(event *proto.Event)
}

type PluginClient

type PluginClient struct {
	shared.TailpipePluginClientWrapper
	Name string
	// contains filtered or unexported fields
}

PluginClient is the client object used by clients of the plugin

func NewPluginClient

func NewPluginClient(client *plugin.Client, pluginName string) (*PluginClient, error)

func (*PluginClient) Exited

func (c *PluginClient) Exited() bool

Exited returned whether the underlying client has exited, i.e. the plugin has terminated

type PluginManager

type PluginManager struct {
	// map of running plugins, keyed by plugin name
	Plugins map[string]*PluginClient
	// contains filtered or unexported fields
}

func New

func New() *PluginManager

func (*PluginManager) AddObserver

func (p *PluginManager) AddObserver(o Observer)

AddObserver adds an observer to the plugin manager

func (*PluginManager) Close

func (p *PluginManager) Close()

func (*PluginManager) Collect

func (p *PluginManager) Collect(ctx context.Context, partition *config.Partition, inboxPath string, collectionState string) (*CollectResponse, error)

Collect starts the plugin if needed, discovers the artifacts and download them for the given partition.

func (*PluginManager) Describe

func (p *PluginManager) Describe(ctx context.Context, pluginName string) (*DescribeResponse, error)

Describe starts the plugin if needed, discovers the artifacts and download them for the given partition.

Jump to

Keyboard shortcuts

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