Documentation ¶
Index ¶
- Constants
- Variables
- func Compare(al, bl *pb.LogItem) int
- type Aggregation
- type AggregationBucket
- type AggregationDescriptor
- type AggregationResponse
- type AggregationResult
- type AggregationType
- type Aggregator
- type Comparer
- type Filter
- type HistogramAggOptions
- type IterateStyle
- type Logs
- type MergedAggregator
- type Operator
- type QueryMeta
- type ResultSkip
- type ReturnFieldMode
- type Selector
- type Storage
- type TermsAggOptions
- type UniqueId
Constants ¶
View Source
const ( IsLive = "is_live" SelectorKeyCount = "count" IsFirstQuery = "is_first_query" // container meta ContainerName = "container_name" PodName = "pod_name" PodNamespace = "pod_namespace" ClusterName = "cluster_name" ID = "id" PipelineID = "pipelineID" // fall back IsFallBack = "is_fall_back" )
View Source
const ( AllFields = ReturnFieldMode(0) ExcludeTagsField = ReturnFieldMode(1) OnlyIdContent = ReturnFieldMode(2) )
View Source
const ( Default = IterateStyle(0) SearchAfter = IterateStyle(1) Scroll = IterateStyle(2) )
View Source
const ( AggregationHistogram = AggregationType("histogram") AggregationTerms = AggregationType("terms") )
Variables ¶
View Source
var DefaultComparer = Comparer{}
DefaultComparer
Functions ¶
Types ¶
type Aggregation ¶
type Aggregation struct { *Selector Aggs []*AggregationDescriptor }
type AggregationBucket ¶
type AggregationBucket struct { Key interface{} Count int64 }
type AggregationDescriptor ¶
type AggregationDescriptor struct { Name string Field string Typ AggregationType Options interface{} }
type AggregationResponse ¶
type AggregationResponse struct { Total int64 Aggregations map[string]*AggregationResult }
type AggregationResult ¶
type AggregationResult struct {
Buckets []*AggregationBucket
}
type AggregationType ¶
type AggregationType string
type Aggregator ¶
type Aggregator interface {
Aggregate(ctx context.Context, req *Aggregation) (*AggregationResponse, error)
}
func NewMergedAggregator ¶
func NewMergedAggregator(aggregators ...Aggregator) (Aggregator, error)
type HistogramAggOptions ¶
type IterateStyle ¶
type IterateStyle int32
type MergedAggregator ¶
type MergedAggregator struct {
// contains filtered or unexported fields
}
func (*MergedAggregator) Aggregate ¶
func (m *MergedAggregator) Aggregate(ctx context.Context, req *Aggregation) (*AggregationResponse, error)
type QueryMeta ¶
type QueryMeta struct { OrgNames []string MspEnvIds []string Highlight bool PreferredBufferSize int PreferredIterateStyle IterateStyle PreferredReturnFields ReturnFieldMode }
type ResultSkip ¶
type ReturnFieldMode ¶
type ReturnFieldMode int32
type Selector ¶
type Selector struct { Start int64 End int64 Scheme string Filters []*Filter Debug bool Meta QueryMeta Skip ResultSkip Options map[string]interface{} }
Selector .
type Storage ¶
type Storage interface { NewWriter(ctx context.Context) (storekit.BatchWriter, error) Iterator(ctx context.Context, sel *Selector) (storekit.Iterator, error) }
Storage .
type TermsAggOptions ¶
type TermsAggOptions struct { Size int64 Missing interface{} }
Click to show internal directories.
Click to hide internal directories.