Documentation
¶
Index ¶
- type Config
- type Instance
- type MockInstance
- func (_m *MockInstance) GetMetrics(ctx context.Context, metric string, service string, groupByOperation string, ...) (map[string]interface{}, error)
- func (_m *MockInstance) GetName() string
- func (_m *MockInstance) GetOperations(ctx context.Context, service string) (map[string]interface{}, error)
- func (_m *MockInstance) GetServices(ctx context.Context) (map[string]interface{}, error)
- func (_m *MockInstance) GetTrace(ctx context.Context, traceID string) (map[string]interface{}, error)
- func (_m *MockInstance) GetTraces(ctx context.Context, limit string, maxDuration string, minDuration string, ...) (map[string]interface{}, error)
- type NewMockInstanceT
- type ResponseError
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
Address string `json:"address"`
Username string `json:"username"`
Password string `json:"password"`
Token string `json:"token"`
}
Config is the structure of the configuration for a single Jaeger database instance.
type Instance ¶
type Instance interface {
GetName() string
GetServices(ctx context.Context) (map[string]any, error)
GetOperations(ctx context.Context, service string) (map[string]any, error)
GetTraces(ctx context.Context, limit, maxDuration, minDuration, operation, service, tags string, timeStart, timeEnd int64) (map[string]any, error)
GetTrace(ctx context.Context, traceID string) (map[string]any, error)
GetMetrics(ctx context.Context, metric, service, groupByOperation, quantile, ratePer, step string, spanKinds []string, timeStart, timeEnd int64) (map[string]any, error)
// contains filtered or unexported methods
}
type MockInstance ¶
MockInstance is an autogenerated mock type for the Instance type
func NewMockInstance ¶
func NewMockInstance(t NewMockInstanceT) *MockInstance
NewMockInstance creates a new instance of MockInstance. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.
func (*MockInstance) GetMetrics ¶ added in v0.11.0
func (_m *MockInstance) GetMetrics(ctx context.Context, metric string, service string, groupByOperation string, quantile string, ratePer string, step string, spanKinds []string, timeStart int64, timeEnd int64) (map[string]interface{}, error)
GetMetrics provides a mock function with given fields: ctx, metric, service, groupByOperation, quantile, ratePer, step, spanKinds, timeStart, timeEnd
func (*MockInstance) GetName ¶
func (_m *MockInstance) GetName() string
GetName provides a mock function with given fields:
func (*MockInstance) GetOperations ¶
func (_m *MockInstance) GetOperations(ctx context.Context, service string) (map[string]interface{}, error)
GetOperations provides a mock function with given fields: ctx, service
func (*MockInstance) GetServices ¶
func (_m *MockInstance) GetServices(ctx context.Context) (map[string]interface{}, error)
GetServices provides a mock function with given fields: ctx
func (*MockInstance) GetTrace ¶
func (_m *MockInstance) GetTrace(ctx context.Context, traceID string) (map[string]interface{}, error)
GetTrace provides a mock function with given fields: ctx, traceID
func (*MockInstance) GetTraces ¶
func (_m *MockInstance) GetTraces(ctx context.Context, limit string, maxDuration string, minDuration string, operation string, service string, tags string, timeStart int64, timeEnd int64) (map[string]interface{}, error)
GetTraces provides a mock function with given fields: ctx, limit, maxDuration, minDuration, operation, service, tags, timeStart, timeEnd
type NewMockInstanceT ¶
type ResponseError ¶
type ResponseError struct {
Errors []struct {
Code int `json:"code"`
Msg string `json:"msg"`
} `json:"errors"`
}
ResponseError is the structure for a failed Jaeger API request.