Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FieldIterator ¶
type SamplesView ¶
type StagingTable ¶
StagingTable is a table structure responsible for storing samples with metrics and dimensions. StagingTable uses two Samples tables one for writes and one for reads in order to prevent lock contention.
func NewStagingTable ¶
func NewStagingTable(s *schema.Schema, limits limits.Limits) *StagingTable
func (*StagingTable) Add ¶
func (t *StagingTable) Add(fieldIterator FieldIterator) error
Add adds input sample in form of fields to write table. Single field could be a metric or a dimension, interpretation depend on the defined schema. Fields are interpreted in the order of fields defined in the table schema. Fields format: - metric: number represented as hex string - dimension: string representing dimension value, or in format which will be used by Field transform function
func (*StagingTable) ReadSnapshot ¶
func (t *StagingTable) ReadSnapshot(resetLookups bool) (SamplesView, LookupSet)
ReadSnapshot creates samples read snapshot and returns view on it. Previous read snapshot will be cleared. By default returned LookupSet is nil. resetLookups determines if new instance of LookupSet should be created, old one will be returned in case of reset
,as Samples and LookupSet reset need to be done atomically this function do both functionalities instead of separate methods