Versions in this module Expand all Collapse all v1 v1.2.10 Mar 24, 2026 Changes in this version + const DefaultBatchSize + const DefaultCompressionLevel + const DefaultMaxRetries + const DefaultTimeout + const NoCompression + func ConvertToTimeSeries(metrics []types.ParquetMetric) []prompb.TimeSeries + func CreateWriteRequest(timeSeries []prompb.TimeSeries) *prompb.WriteRequest + func FindFiles(dir string, filter func(path string) bool) ([]string, error) + func FindSupportedFiles(dir string) ([]string, error) + func IsSupportedFile(path string) bool + func MetricToTimeSeries(m types.Metric) prompb.TimeSeries + func TimeSeriesToMetrics(ts prompb.TimeSeries) []types.Metric + type CAdvisorMetric struct + Labels map[string]string + Timestamp time.Time + Value float64 + type CSVReader struct + func NewCSVReader(batchSize int) *CSVReader + func (r *CSVReader) ReadCSVFile(path string, callback func([]prompb.TimeSeries) error) error + type CSVWriter struct + func NewCSVWriter(path string) (*CSVWriter, error) + func NewCSVWriterToWriter(dest io.Writer) (*CSVWriter, error) + func (w *CSVWriter) Close() error + func (w *CSVWriter) Write(metrics []types.Metric) error + func (w *CSVWriter) WriteOne(metric types.Metric) error + type JSONReader struct + func NewJSONReader(batchSize int) *JSONReader + func (r *JSONReader) ReadAllMetrics(path string) ([]types.Metric, error) + func (r *JSONReader) ReadFromReader(reader io.Reader, callback func([]types.Metric) error) error + func (r *JSONReader) ReadJSONFile(path string, callback func([]types.Metric) error) error + type JSONWriter struct + func NewJSONWriter(path string) (*JSONWriter, error) + func NewJSONWriterToWriter(dest io.Writer, compressionLevel int) (*JSONWriter, error) + func NewJSONWriterWithCompression(path string, compressionLevel int) (*JSONWriter, error) + func (w *JSONWriter) Close() error + func (w *JSONWriter) Write(metrics []types.Metric) error + func (w *JSONWriter) WriteOne(metric types.Metric) error + type ParquetReader struct + func NewParquetReader(batchSize int) *ParquetReader + func (r *ParquetReader) ReadFile(path string, callback func([]types.ParquetMetric) error) error + func (r *ParquetReader) ReadFiles(paths []string, ...) error + type ParquetWriter struct + func NewParquetWriter(path string) (*ParquetWriter, error) + func NewParquetWriterToWriter(dest io.Writer) (*ParquetWriter, error) + func (w *ParquetWriter) Close() error + func (w *ParquetWriter) Write(metrics []types.Metric) error + func (w *ParquetWriter) WriteOne(metric types.Metric) error + func (w *ParquetWriter) WriteParquetMetrics(metrics []types.ParquetMetric) error + type RemoteWriter struct + func NewRemoteWriter(url string) *RemoteWriter + func (w *RemoteWriter) Write(ctx context.Context, timeSeries []prompb.TimeSeries) error