Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ReadPointMsg ¶
func WritePointMsg ¶
WritePointMsg is like CreateMsg, except optimized for MetricPoint and buffer re-use. caller must assure a cap-len diff of at least: 33B (for FormatMetricPoint) 29B (for FormatMetricPointWithoutOrg) no other formats supported.
Types ¶
type Format ¶
type Format uint8
const ( FormatMetricDataArrayJson Format = iota FormatMetricDataArrayMsgp FormatMetricPoint FormatMetricPointWithoutOrg )
identifier of message format
func IsPointMsg ¶
type MetricData ¶
type MetricData struct { Id int64 Metrics []*schema.MetricData Produced time.Time Format Format Msg []byte }
func (*MetricData) DecodeMetricData ¶
func (m *MetricData) DecodeMetricData() error
sets m.Metrics to a []*schema.MetricData any subsequent call may however put different MetricData into our m.Metrics array
func (*MetricData) InitFromMsg ¶
func (m *MetricData) InitFromMsg(msg []byte) error
parses format and id (cheap), but doesn't decode metrics (expensive) just yet.
Click to show internal directories.
Click to hide internal directories.