du

package
v0.1.3 Latest Latest
Warning

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

Go to latest
Published: May 24, 2024 License: MIT Imports: 14 Imported by: 0

Documentation

Overview

Package du is the link between cloud storage and du (disk usage) data

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AzureBlobInventoryReportConfig

type AzureBlobInventoryReportConfig struct {
	AzureStorageConnectionString string `` /* 258-byte string literal not displayed */
	BlobInventoryContainer       string `yaml:"BlobInventoryContainer" default:"blob-inventory"`
	MaxMemory                    string `yaml:"maxMemory" default:"1GB"`
	Threads                      int    `yaml:"threads" default:"4"`
}

func (*AzureBlobInventoryReportConfig) UnmarshalYAML

func (c *AzureBlobInventoryReportConfig) UnmarshalYAML(unmarshal func(any) error) error

type AzureBlobInventoryReportDuReader

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

func (*AzureBlobInventoryReportDuReader) GetStorageAccountName added in v0.1.1

func (ar *AzureBlobInventoryReportDuReader) GetStorageAccountName() string

func (*AzureBlobInventoryReportDuReader) Read

func (ar *AzureBlobInventoryReportDuReader) Read(previousRunDate time.Time) (time.Time, <-chan Row, <-chan error, error)

func (*AzureBlobInventoryReportDuReader) TestConnection

func (ar *AzureBlobInventoryReportDuReader) TestConnection() error

type Reader

type Reader interface {
	Read(previousRunDate time.Time) (runDate time.Time, rows <-chan Row, errs <-chan error, err error)
	TestConnection() error
	GetStorageAccountName() string
}

Reader provides Row s from a cloud storage provider

The runDate indicates the actuality of the data. If there is no new data, the returned runDate will be the same and the channel nil.

type Row

type Row struct {
	Dir     string       `db:"dir"`
	Deleted *bool        `db:"deleted"`
	Bytes   StorageUsage `db:"bytes"`
	Count   int64        `db:"cnt"`
}

Row is info about the aggregated size of a specific dir (or prefix if you will) in cloud storage

type StorageUsage

type StorageUsage = int64

StorageUsage is storage usage/size in bytes

Jump to

Keyboard shortcuts

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