Documentation
¶
Index ¶
- func NewWriter(cfg engine.WriterConfig) engine.IWriter
- type Config
- type Flags
- type Stat
- func (s *Stat) AddSubStat(engine.Stat)
- func (s *Stat) GetCurrentProgress(_ ...interface{}) map[string]interface{}
- func (s *Stat) GetFormattedSummary() string
- func (s *Stat) GetName() string
- func (s *Stat) GetProgress() string
- func (s *Stat) GetSubStats() []engine.Stat
- func (s *Stat) GetSummary() string
- func (s *Stat) GetTableCompressRatio() (float64, error)
- type Writer
- func (w *Writer) CreatePluginConfig() interface{}
- func (w *Writer) GetDefaultFlags() (*pflag.FlagSet, interface{})
- func (w *Writer) GetStat() engine.Stat
- func (w *Writer) IsNil() bool
- func (w *Writer) Start(cfg engine.Config, volumeDesc engine.VolumeDesc) (<-chan error, error)
- func (w *Writer) Stop() error
- func (w *Writer) Write(m []byte, cnt, size int64) error
- func (w *Writer) WriteEOF() error
- type WriterProgress
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Config ¶
type Config struct { StreamPrepared int `mapstructure:"writer-stream-prepared"` Interval int `mapstructure:"writer-interval"` ProgressFormat string `mapstructure:"writer-progress-format"` ProgressIncludeTableSize bool `mapstructure:"writer-progress-include-table-size"` ProgressWithTimezone bool `mapstructure:"writer-progress-with-timezone"` // contains filtered or unexported fields }
type Stat ¶
type Stat struct {
// contains filtered or unexported fields
}
func (*Stat) AddSubStat ¶
func (*Stat) GetCurrentProgress ¶
func (*Stat) GetFormattedSummary ¶
GetFormattedSummary is aimed at outputing statistics in certain format. No data in will be rounded.
func (*Stat) GetProgress ¶
func (*Stat) GetSubStats ¶
func (*Stat) GetSummary ¶
GetSummary is aimed at presenting statistics to the user in the form of a table empowered by go-pretty. Any data in float will be rounded to 2 decimal places.
func (*Stat) GetTableCompressRatio ¶
type Writer ¶
type Writer struct {
// contains filtered or unexported fields
}
func (*Writer) CreatePluginConfig ¶
func (w *Writer) CreatePluginConfig() interface{}
func (*Writer) GetDefaultFlags ¶
type WriterProgress ¶
type WriterProgress struct { Start string `json:"start"` End string `json:"end"` Period string `json:"period"` CurrTotalRows int64 `json:"currTotalRows"` TotalRows int64 `json:"totalRows"` CurrPeriodRows int64 `json:"currPeriodRows"` CurrTotalBytes int64 `json:"currTotalBytes"` TotalBytes int64 `json:"totalBytes"` CurrPeriodBytes int64 `json:"currPeriodBytes"` WrittenMxgateTotal int64 `json:"writtenMxGateTotal"` CurrPeriodWrittenMxgate int64 `json:"currPeriodWrittenMxGate"` TableSize int64 `json:"tableSize"` }
Click to show internal directories.
Click to hide internal directories.