Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func FormatTimestamp ¶ added in v1.4.0
FormatTimestamp converts a nanosecond Unix timestamp string to a human-readable format.
func NormalizeTimestamp ¶
NormalizeTimestamp normalizes an absolute timestamp to the format required by the Dash0 API (RFC 3339 with millisecond precision). Relative expressions like "now" and "now-1h" are returned as-is.
func ParseFilter ¶
func ParseFilter(s string) (dash0api.AttributeFilter, error)
ParseFilter parses a single filter string into an AttributeFilter.
Format: key [operator] value
- If key starts with single quote, consume until closing quote
- Next token is checked against known operators
- If it matches: use that operator, rest is value
- If no match: implicit "is" operator, rest (from that token) is value
- is_set/is_not_set expect no value
- is_one_of/is_not_one_of split value on whitespace (single-quoted tokens may contain spaces)
func ParseFilters ¶
func ParseFilters(filterStrings []string) (*dash0api.FilterCriteria, error)
ParseFilters parses a list of filter strings into FilterCriteria.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.