scanner

package
v0.0.0-...-d8f7d12 Latest Latest
Warning

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

Go to latest
Published: Apr 12, 2020 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CompareFileSystems

func CompareFileSystems(left, right *FileSystem, logWriter io.Writer) bool

func StartScannerDaemon

func StartScannerDaemon(rootDirectoryName string, cacheDirectoryName string,
	configuration *Configuration, logger log.Logger) (
	<-chan *FileSystem, func(disableScanner bool))

func StartScanning

func StartScanning(rootDirectoryName string, cacheDirectoryName string,
	configuration *Configuration, logger log.Logger,
	mainFunc func(<-chan *FileSystem, func(disableScanner bool)))

Types

type Configuration

type Configuration struct {
	CpuLimiter           *cpulimiter.CpuLimiter
	DefaultCpuPercent    uint
	FsScanContext        *fsrateio.ReaderContext
	NetworkReaderContext *rateio.ReaderContext
	ScanFilter           *filter.Filter
}

func (*Configuration) BoostCpuLimit

func (configuration *Configuration) BoostCpuLimit(logger log.Logger)

func (*Configuration) RegisterMetrics

func (configuration *Configuration) RegisterMetrics(
	dir *tricorder.DirectorySpec) error

func (*Configuration) RestoreCpuLimit

func (configuration *Configuration) RestoreCpuLimit(logger log.Logger)

func (*Configuration) WriteHtml

func (configuration *Configuration) WriteHtml(writer io.Writer)

type FileSystem

type FileSystem struct {
	scanner.FileSystem

	objectcache.ObjectCache
	// contains filtered or unexported fields
}

func ScanFileSystem

func ScanFileSystem(rootDirectoryName string, cacheDirectoryName string,
	configuration *Configuration) (*FileSystem, error)

func (*FileSystem) Configuration

func (fs *FileSystem) Configuration() *Configuration

func (*FileSystem) RootDirectoryName

func (fs *FileSystem) RootDirectoryName() string

func (*FileSystem) ScanObjectCache

func (fs *FileSystem) ScanObjectCache() error

func (*FileSystem) String

func (fs *FileSystem) String() string

func (*FileSystem) WriteHtml

func (fs *FileSystem) WriteHtml(writer io.Writer)

type FileSystemHistory

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

func (*FileSystemHistory) DurationOfLastScan

func (fsh *FileSystemHistory) DurationOfLastScan() time.Duration

func (*FileSystemHistory) FileSystem

func (fsh *FileSystemHistory) FileSystem() *FileSystem

func (*FileSystemHistory) GenerationCount

func (fsh *FileSystemHistory) GenerationCount() uint64

func (*FileSystemHistory) ScanCount

func (fsh *FileSystemHistory) ScanCount() uint64

func (*FileSystemHistory) String

func (fsh *FileSystemHistory) String() string

func (*FileSystemHistory) Update

func (fsh *FileSystemHistory) Update(newFS *FileSystem)

func (*FileSystemHistory) UpdateObjectCacheOnly

func (fsh *FileSystemHistory) UpdateObjectCacheOnly() error

func (*FileSystemHistory) WriteHtml

func (fsh *FileSystemHistory) WriteHtml(writer io.Writer)

Jump to

Keyboard shortcuts

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