Documentation ¶
Overview ¶
Package capture implements datacapture for the builtin datamanger
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Capture ¶ added in v0.44.0
type Capture struct {
// contains filtered or unexported fields
}
Capture polls data sources (resource/method pairs) and writes the responses files. There must be only one Capture per DataManager.
The lifecycle of a Capture is:
- New - Reconfigure (any number of times) - Close (any number of times).
func (*Capture) Close ¶ added in v0.44.0
func (c *Capture) Close()
Close closes the capture manager.
func (*Capture) FlushCollectors ¶ added in v0.44.0
func (c *Capture) FlushCollectors()
FlushCollectors flushes collectors.
func (*Capture) Reconfigure ¶ added in v0.44.0
func (c *Capture) Reconfigure( ctx context.Context, collectorConfigsByResource CollectorConfigsByResource, config Config, )
Reconfigure reconfigures Capture. It is only called by the builtin data manager.
type CollectorConfigsByResource ¶ added in v0.44.0
type CollectorConfigsByResource map[resource.Resource][]datamanager.DataCaptureConfig
CollectorConfigsByResource describes the data capture configuration of the resources/mathod pairs which data capture should capture data from.
type Config ¶
type Config struct { // CaptureDisabled if set to true disables all data capture collectors CaptureDisabled bool // CaptureDir defines where data capture should write capture files CaptureDir string // Tags defines the tags that should be added to capture file metadata Tags []string // MaximumCaptureFileSizeBytes defines the maximum size that in progress data capture // (.prog) files should be allowed to grow to before they are convered into .capture // files MaximumCaptureFileSizeBytes int64 }
Config is the capture config.
Click to show internal directories.
Click to hide internal directories.