filesystem

package
v3.46.2 Latest Latest
Warning

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

Go to latest
Published: Aug 1, 2023 License: AGPL-3.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// These buffer sizes are mainly driven by our largest credential size, which is GCP @ ~2.25KB.
	// Having a peek size larger than that ensures that we have complete credential coverage in our chunks.
	BufferSize = 10 * 1024 // 10KB
	PeekSize   = 3 * 1024  // 3KB
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Source

type Source struct {
	sources.Progress
	sources.CommonSourceUnitUnmarshaller
	// contains filtered or unexported fields
}

func (*Source) ChunkUnit added in v3.45.0

func (s *Source) ChunkUnit(ctx context.Context, unit sources.SourceUnit, reporter sources.ChunkReporter) error

ChunkUnit implements SourceUnitChunker interface.

func (*Source) Chunks

func (s *Source) Chunks(ctx context.Context, chunksChan chan *sources.Chunk) error

Chunks emits chunks of bytes over a channel.

func (*Source) Enumerate added in v3.44.0

func (s *Source) Enumerate(ctx context.Context, reporter sources.UnitReporter) error

Enumerate implements SourceUnitEnumerator interface. This implementation simply passes the configured paths as the source unit, whether it be a single filepath or a directory.

func (*Source) Init

func (s *Source) Init(aCtx context.Context, name string, jobId, sourceId int64, verify bool, connection *anypb.Any, _ int) error

Init returns an initialized Filesystem source.

func (*Source) JobID

func (s *Source) JobID() int64

func (*Source) SourceID

func (s *Source) SourceID() int64

func (*Source) Type

func (s *Source) Type() sourcespb.SourceType

Type returns the type of source. It is used for matching source types in configuration and job input.

func (*Source) WithFilter added in v3.26.0

func (s *Source) WithFilter(filter *common.Filter)

Jump to

Keyboard shortcuts

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