Documentation ¶
Index ¶
- Constants
- func NewExternalClient(controlPlaneNamespace string, kubeApi k8s.KubernetesApi) (pb.ApiClient, error)
- func NewInternalClient(kubernetesApiHost string) (pb.ApiClient, error)
- func NewServer(addr string, prometheusClient promApi.Client, tapClient tapPb.TapClient, ...) *http.Server
- type MockApi_TapByResourceClient
- type MockApi_TapClient
- type MockConduitApiClient
- func (c *MockConduitApiClient) ListPods(ctx context.Context, in *pb.Empty, opts ...grpc.CallOption) (*pb.ListPodsResponse, error)
- func (c *MockConduitApiClient) SelfCheck(ctx context.Context, in *healthcheckPb.SelfCheckRequest, _ ...grpc.CallOption) (*healthcheckPb.SelfCheckResponse, error)
- func (c *MockConduitApiClient) StatSummary(ctx context.Context, in *pb.StatSummaryRequest, opts ...grpc.CallOption) (*pb.StatSummaryResponse, error)
- func (c *MockConduitApiClient) Tap(ctx context.Context, in *pb.TapRequest, opts ...grpc.CallOption) (pb.Api_TapClient, error)
- func (c *MockConduitApiClient) TapByResource(ctx context.Context, in *pb.TapByResourceRequest, opts ...grpc.CallOption) (pb.Api_TapByResourceClient, error)
- func (c *MockConduitApiClient) Version(ctx context.Context, in *pb.Empty, opts ...grpc.CallOption) (*pb.VersionInfo, error)
- type MockProm
- func (m *MockProm) LabelValues(ctx context.Context, label string) (model.LabelValues, error)
- func (m *MockProm) Query(ctx context.Context, query string, ts time.Time) (model.Value, error)
- func (m *MockProm) QueryRange(ctx context.Context, query string, r v1.Range) (model.Value, error)
- func (m *MockProm) Series(ctx context.Context, matches []string, startTime time.Time, endTime time.Time) ([]model.LabelSet, error)
Constants ¶
View Source
const ( K8sClientSubsystemName = "kubernetes" K8sClientCheckDescription = "control plane can talk to Kubernetes" PromClientSubsystemName = "prometheus" PromClientCheckDescription = "control plane can talk to Prometheus" )
View Source
const (
ConduitApiSubsystemName = "conduit-api"
)
Variables ¶
This section is empty.
Functions ¶
func NewExternalClient ¶ added in v0.1.2
func NewInternalClient ¶ added in v0.1.2
Types ¶
type MockApi_TapByResourceClient ¶ added in v0.4.1
type MockApi_TapByResourceClient struct { TapEventsToReturn []common.TapEvent ErrorsToReturn []error grpc.ClientStream }
type MockApi_TapClient ¶ added in v0.1.2
type MockApi_TapClient struct { TapEventsToReturn []common.TapEvent ErrorsToReturn []error grpc.ClientStream }
type MockConduitApiClient ¶ added in v0.1.2
type MockConduitApiClient struct { ErrorToReturn error VersionInfoToReturn *pb.VersionInfo ListPodsResponseToReturn *pb.ListPodsResponse StatSummaryResponseToReturn *pb.StatSummaryResponse SelfCheckResponseToReturn *healthcheckPb.SelfCheckResponse Api_TapClientToReturn pb.Api_TapClient Api_TapByResourceClientToReturn pb.Api_TapByResourceClient }
func (*MockConduitApiClient) ListPods ¶ added in v0.1.2
func (c *MockConduitApiClient) ListPods(ctx context.Context, in *pb.Empty, opts ...grpc.CallOption) (*pb.ListPodsResponse, error)
func (*MockConduitApiClient) SelfCheck ¶ added in v0.1.2
func (c *MockConduitApiClient) SelfCheck(ctx context.Context, in *healthcheckPb.SelfCheckRequest, _ ...grpc.CallOption) (*healthcheckPb.SelfCheckResponse, error)
func (*MockConduitApiClient) StatSummary ¶ added in v0.4.0
func (c *MockConduitApiClient) StatSummary(ctx context.Context, in *pb.StatSummaryRequest, opts ...grpc.CallOption) (*pb.StatSummaryResponse, error)
func (*MockConduitApiClient) Tap ¶ added in v0.1.2
func (c *MockConduitApiClient) Tap(ctx context.Context, in *pb.TapRequest, opts ...grpc.CallOption) (pb.Api_TapClient, error)
func (*MockConduitApiClient) TapByResource ¶ added in v0.4.1
func (c *MockConduitApiClient) TapByResource(ctx context.Context, in *pb.TapByResourceRequest, opts ...grpc.CallOption) (pb.Api_TapByResourceClient, error)
func (*MockConduitApiClient) Version ¶ added in v0.1.2
func (c *MockConduitApiClient) Version(ctx context.Context, in *pb.Empty, opts ...grpc.CallOption) (*pb.VersionInfo, error)
type MockProm ¶ added in v0.4.0
type MockProm struct { Res model.Value QueriesExecuted []string // expose the queries our Mock Prometheus receives, to test query generation // contains filtered or unexported fields }
func (*MockProm) LabelValues ¶ added in v0.4.0
func (*MockProm) QueryRange ¶ added in v0.4.0
Click to show internal directories.
Click to hide internal directories.