Documentation
¶
Overview ¶
Package logs provides utilities for managing and manipulating log in Arrow format.
Index ¶
- type BinaryReader
- type Iterator
- type LogBuilder
- type Reader
- func (r *Reader) Attributes(row int, fn func(key, value string))
- func (r *Reader) AttributesToMap(row int, mb *array.MapBuilder, k, v *array.StringBuilder)
- func (r *Reader) EventName(row int) string
- func (r *Reader) Iterator() *Iterator
- func (r *Reader) Level(row int) string
- func (r *Reader) Message(row int) string
- func (r *Reader) NumRows() int
- func (r *Reader) Reset(logs, attrs arrow.RecordBatch)
- func (r *Reader) SpanID(row int) []byte
- func (r *Reader) Timestamp(row int) int64
- func (r *Reader) TraceID(row int) []byte
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BinaryReader ¶
type BinaryReader struct {
// contains filtered or unexported fields
}
func NewBinaryReader ¶
func NewBinaryReader() (*BinaryReader, error)
func (*BinaryReader) ReadFrom ¶
func (r *BinaryReader) ReadFrom(data []byte) (logs, attrs arrow.RecordBatch, err error)
func (*BinaryReader) Release ¶
func (r *BinaryReader) Release()
type Iterator ¶
type Iterator struct {
// contains filtered or unexported fields
}
func NewIterator ¶
type LogBuilder ¶
type LogBuilder struct {
// contains filtered or unexported fields
}
LogBuilder represents a builder for log entries.
func NewLogBuilder ¶
func NewLogBuilder(allocator memory.Allocator) *LogBuilder
NewLogBuilder creates a new LogsBuilder with the given memory allocator.
func (*LogBuilder) Append ¶
func (lb *LogBuilder) Append(log *model.Log)
func (*LogBuilder) Build ¶
func (lb *LogBuilder) Build() []arrow.RecordBatch
Build builds and returns the attributes and logs record batches.
func (*LogBuilder) Bytes ¶
func (lb *LogBuilder) Bytes() ([]byte, error)
func (*LogBuilder) NumOfRows ¶
func (lb *LogBuilder) NumOfRows() int
NumOfRows returns the number of log entries appended so far.
func (*LogBuilder) Release ¶
func (lb *LogBuilder) Release() error
Release releases the resources held by the LogsBuilder.
func (*LogBuilder) Schemas ¶
func (lb *LogBuilder) Schemas() []*arrow.Schema
Schemas returns the schemas for the attributes and logs record batches.
type Reader ¶
type Reader struct {
// contains filtered or unexported fields
}
func NewReader ¶
func NewReader(logs, attrs arrow.RecordBatch) *Reader
func (*Reader) Attributes ¶
func (*Reader) AttributesToMap ¶
func (r *Reader) AttributesToMap(row int, mb *array.MapBuilder, k, v *array.StringBuilder)
func (*Reader) Reset ¶
func (r *Reader) Reset(logs, attrs arrow.RecordBatch)
Click to show internal directories.
Click to hide internal directories.