Documentation ¶
Index ¶
- type Labels
- type LogsCountResponse
- type MetadataFilters
- type MetricCounts
- type MetricSample
- type MetricsSamplesByTime
- type ReceiverMockClient
- func (client *ReceiverMockClient) GetLogsCount(t *testing.T, metadataFilters MetadataFilters) (uint, error)
- func (client *ReceiverMockClient) GetMetricCounts(t *testing.T) (MetricCounts, error)
- func (client *ReceiverMockClient) GetMetricsSamples(metadataFilters MetadataFilters) ([]MetricSample, error)
- func (client *ReceiverMockClient) GetSpansCount(t *testing.T, metadataFilters MetadataFilters) (uint, error)
- func (client *ReceiverMockClient) GetTracesCounts(t *testing.T, metadataFilters MetadataFilters) ([]uint, error)
- type Span
- type SpanId
- type TraceId
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Labels ¶
Labels represent a key value mapping of labels names and their values. An empty label value indicates that we're interested in a label being present but we don't care about it's value.
func (Labels) MatchAll ¶
MatchAll matches returns whether all the requested labels are present and (if a corresponding value has been provided) that all values match matching is done via regex if the value is a valid regex, otherwise via strict equality the special value "" matches everything for historical reasons
type LogsCountResponse ¶
type LogsCountResponse struct {
Count uint
}
type MetadataFilters ¶
type MetricCounts ¶
Mapping of metric names to the number of times the metric was observed
type MetricSample ¶
type MetricsSamplesByTime ¶
type MetricsSamplesByTime []MetricSample
func (MetricsSamplesByTime) Len ¶
func (m MetricsSamplesByTime) Len() int
func (MetricsSamplesByTime) Less ¶
func (m MetricsSamplesByTime) Less(i, j int) bool
func (MetricsSamplesByTime) Swap ¶
func (m MetricsSamplesByTime) Swap(i, j int)
type ReceiverMockClient ¶
type ReceiverMockClient struct {
// contains filtered or unexported fields
}
A HTTP client for the receiver-mock API
func NewClientWithK8sTunnel ¶
func NewClientWithK8sTunnel( ctx context.Context, t *testing.T, ) (*ReceiverMockClient, func())
NewClientWithK8sTunnel creates a client for receiver-mock. It return the client itself and a tunnel teardown func which should be called by the caller when they're done with it.
func (*ReceiverMockClient) GetLogsCount ¶
func (client *ReceiverMockClient) GetLogsCount(t *testing.T, metadataFilters MetadataFilters) (uint, error)
GetLogsCount returns the numbers of logs received by receiver-mock that pass the provided metadata filter. Note that in the filter semantics, empty strings match any value
func (*ReceiverMockClient) GetMetricCounts ¶
func (client *ReceiverMockClient) GetMetricCounts(t *testing.T) (MetricCounts, error)
GetMetricCounts returns the number of times each metric was received by receiver-mock
func (*ReceiverMockClient) GetMetricsSamples ¶
func (client *ReceiverMockClient) GetMetricsSamples( metadataFilters MetadataFilters, ) ([]MetricSample, error)
GetMetricSamples returns metric samples received by receiver-mock that pass the provided metadata filter. Note that in the filter semantics, empty strings match any value
func (*ReceiverMockClient) GetSpansCount ¶
func (client *ReceiverMockClient) GetSpansCount(t *testing.T, metadataFilters MetadataFilters) (uint, error)
func (*ReceiverMockClient) GetTracesCounts ¶
func (client *ReceiverMockClient) GetTracesCounts(t *testing.T, metadataFilters MetadataFilters) ([]uint, error)