logs

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: Feb 25, 2026 License: AGPL-3.0 Imports: 16 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

View Source
const (
	BatchFlushInterval = 50 * time.Millisecond
	BatchMaxSize       = 100
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	// contains filtered or unexported fields
}

func NewClient

func NewClient(controller Controller) *Client

func (*Client) CloseSession

func (c *Client) CloseSession(sessionID string) error

func (*Client) CreateSession

func (c *Client) CreateSession(
	plugin, connectionID string,
	opts sdklogs.CreateSessionOptions,
) (*sdklogs.LogSession, error)

func (*Client) GetSession

func (c *Client) GetSession(sessionID string) (*sdklogs.LogSession, error)

func (*Client) GetSupportedResources

func (c *Client) GetSupportedResources(pluginID string) []sdklogs.Handler

func (*Client) ListSessions

func (c *Client) ListSessions() ([]*sdklogs.LogSession, error)

func (*Client) PauseSession

func (c *Client) PauseSession(sessionID string) error

func (*Client) ResumeSession

func (c *Client) ResumeSession(sessionID string) error

func (*Client) UpdateSessionOptions

func (c *Client) UpdateSessionOptions(
	sessionID string,
	opts sdklogs.LogSessionOptions,
) (*sdklogs.LogSession, error)

type Controller

type Controller interface {
	internaltypes.Controller
	Run(ctx context.Context)
	GetSupportedResources(pluginID string) []logs.Handler
	CreateSession(plugin, connectionID string, opts logs.CreateSessionOptions) (*logs.LogSession, error)
	GetSession(sessionID string) (*logs.LogSession, error)
	ListSessions() ([]*logs.LogSession, error)
	CloseSession(sessionID string) error
	SendCommand(sessionID string, cmd logs.LogStreamCommand) error
	UpdateSessionOptions(sessionID string, opts logs.LogSessionOptions) (*logs.LogSession, error)
}

Controller manages log sessions across all plugins.

func NewController

func NewController(
	logger *zap.SugaredLogger,
	sp pkgsettings.Provider,
	resourceClient resource.IClient,
) Controller

Jump to

Keyboard shortcuts

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