Documentation
¶
Index ¶
- Constants
- Variables
- func LabelNamesFromSamples(takenLabels map[string]string, stringTable []string, samples []*pprofpb.Sample, ...)
- func LabelsFromSample(takenLabels map[string]string, stringTable []string, plabels []*pprofpb.Label) (map[string]string, map[string]int64)
- func MetaFromOtelProfile(p *pprofextended.Profile, name string, sampleIndex int, duration int64) profile.Meta
- func MetaFromPprof(p *pprofpb.Profile, name string, sampleIndex int) profile.Meta
- func NewArrowToInternalConverter(mem memory.Allocator, schema *dynparquet.Schema, metrics *Metrics) *arrowToInternalConverter
- func OtlpRequestToArrowRecord(ctx context.Context, req *otelgrpcprofilingpb.ExportProfilesServiceRequest, ...) (arrow.Record, error)
- func SampleToParquetRow(schema *dynparquet.Schema, row parquet.Row, ...) parquet.Row
- func ValidateOtelExportProfilesServiceRequest(req *otelgrpcprofilingpb.ExportProfilesServiceRequest) error
- func ValidateOtelProfile(p *otelprofilingpb.Profile) error
- func ValidatePprofProfile(p *pprofpb.Profile, ei []*profilestorepb.ExecutableInfo) error
- func WriteRawRequestToArrowRecord(ctx context.Context, mem memory.Allocator, req *profilestorepb.WriteRawRequest, ...) (arrow.Record, error)
- type InternalRecordBuilderV1
- type Metrics
- type NormalizedProfile
- type NormalizedSample
- type NormalizedWriteRawRequest
- type Series
Constants ¶
View Source
const (
MetadataSchemaVersion = "parca_write_schema_version"
)
View Source
const (
MetadataSchemaVersionV1 = "v1"
)
Variables ¶
View Source
var ErrMissingNameLabel = errors.New("missing __name__ label")
Functions ¶
func LabelNamesFromSamples ¶
func LabelsFromSample ¶
func LabelsFromSample(takenLabels map[string]string, stringTable []string, plabels []*pprofpb.Label) (map[string]string, map[string]int64)
TODO: support num label units.
func MetaFromOtelProfile ¶ added in v0.22.0
func MetaFromPprof ¶ added in v0.22.0
func NewArrowToInternalConverter ¶ added in v0.22.0
func NewArrowToInternalConverter( mem memory.Allocator, schema *dynparquet.Schema, metrics *Metrics, ) *arrowToInternalConverter
func OtlpRequestToArrowRecord ¶ added in v0.22.0
func OtlpRequestToArrowRecord( ctx context.Context, req *otelgrpcprofilingpb.ExportProfilesServiceRequest, schema *dynparquet.Schema, mem memory.Allocator, ) (arrow.Record, error)
func SampleToParquetRow ¶ added in v0.22.0
func SampleToParquetRow( schema *dynparquet.Schema, row parquet.Row, labelNames, profileLabelNames, profileNumLabelNames []string, lset map[string]string, meta profile.Meta, s *NormalizedSample, ) parquet.Row
SampleToParquetRow converts a sample to a Parquet row. The passed labels must be sorted.
func ValidateOtelExportProfilesServiceRequest ¶ added in v0.22.0
func ValidateOtelExportProfilesServiceRequest(req *otelgrpcprofilingpb.ExportProfilesServiceRequest) error
func ValidateOtelProfile ¶ added in v0.22.0
func ValidateOtelProfile(p *otelprofilingpb.Profile) error
func ValidatePprofProfile ¶
func ValidatePprofProfile(p *pprofpb.Profile, ei []*profilestorepb.ExecutableInfo) error
func WriteRawRequestToArrowRecord ¶ added in v0.22.0
func WriteRawRequestToArrowRecord( ctx context.Context, mem memory.Allocator, req *profilestorepb.WriteRawRequest, schema *dynparquet.Schema, ) (arrow.Record, error)
Types ¶
type InternalRecordBuilderV1 ¶ added in v0.22.0
type InternalRecordBuilderV1 struct { Producer *array.Dictionary SampleType *array.Dictionary SampleUnit *array.Dictionary PeriodType *array.Dictionary PeriodUnit *array.Dictionary Period *array.Int64 Duration *array.Int64 Timestamp *array.Int64 Value *array.Int64 Labels []arrow.Array LabelFields []arrow.Field Locations *array.List StacktraceIDs *array.Dictionary }
func (*InternalRecordBuilderV1) Release ¶ added in v0.22.0
func (r *InternalRecordBuilderV1) Release()
type Metrics ¶ added in v0.22.0
type Metrics struct {
IncompleteLocations prometheus.Counter
}
func NewMetrics ¶ added in v0.22.0
func NewMetrics(reg prometheus.Registerer) *Metrics
type NormalizedProfile ¶ added in v0.22.0
type NormalizedProfile struct { Samples []*NormalizedSample Meta profile.Meta }
func NormalizePprof ¶ added in v0.22.0
func NormalizePprof( ctx context.Context, name string, takenLabelNames map[string]string, p *pprofpb.Profile, normalizedAddress bool, executableInfo []*profilestorepb.ExecutableInfo, ) ([]*NormalizedProfile, error)
type NormalizedSample ¶ added in v0.22.0
type NormalizedWriteRawRequest ¶
type NormalizedWriteRawRequest struct { Series []Series AllLabelNames []string AllPprofLabelNames []string AllPprofNumLabelNames []string }
func NormalizeWriteRawRequest ¶ added in v0.22.0
func NormalizeWriteRawRequest(ctx context.Context, req *profilestorepb.WriteRawRequest) (NormalizedWriteRawRequest, error)
type Series ¶
type Series struct { Labels map[string]string Samples [][]*NormalizedProfile }
Click to show internal directories.
Click to hide internal directories.