logs

package
v0.0.0-...-b4871a6 Latest Latest
Warning

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

Go to latest
Published: Jul 27, 2026 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Overview

Package logs provides utilities for managing and manipulating log in Arrow format.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Iterator

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

func NewIterator

func NewIterator(r *Reader) *Iterator

func (*Iterator) HasNext

func (it *Iterator) HasNext() bool

func (*Iterator) Next

func (it *Iterator) Next() int

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(data []byte) (*Reader, error)

func (*Reader) Attributes

func (r *Reader) Attributes(row int, fn func(key, value string))

func (*Reader) AttributesToMap

func (r *Reader) AttributesToMap(row int, mb *array.MapBuilder, k, v *array.StringBuilder)

func (*Reader) EventName

func (r *Reader) EventName(row int) string

func (*Reader) Iterator

func (r *Reader) Iterator() *Iterator

func (*Reader) Level

func (r *Reader) Level(row int) string

func (*Reader) Message

func (r *Reader) Message(row int) string

func (*Reader) NumRows

func (r *Reader) NumRows() int

func (*Reader) Release

func (r *Reader) Release()

func (*Reader) Reset

func (r *Reader) Reset(data []byte) error

func (*Reader) SpanID

func (r *Reader) SpanID(row int) []byte

func (*Reader) Timestamp

func (r *Reader) Timestamp(row int) int64

func (*Reader) TraceID

func (r *Reader) TraceID(row int) []byte

Directories

Path Synopsis
Package v1 provides the Arrow schema definition for version 1 of the logs data structure.
Package v1 provides the Arrow schema definition for version 1 of the logs data structure.

Jump to

Keyboard shortcuts

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