public

package
v0.4.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 16, 2018 License: Apache-2.0 Imports: 40 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ApiRoot                 = "/" // Must be absolute (with a leading slash).
	ApiVersion              = "v1"
	ApiPrefix               = "api/" + ApiVersion + "/" // Must be relative (without a leading slash).
	ConduitApiSubsystemName = "conduit-api"
)
View Source
const (
	K8sClientSubsystemName     = "kubernetes"
	K8sClientCheckDescription  = "control plane can talk to Kubernetes"
	PromClientSubsystemName    = "prometheus"
	PromClientCheckDescription = "control plane can talk to Prometheus"
)

Variables

This section is empty.

Functions

func NewExternalClient added in v0.1.2

func NewExternalClient(controlPlaneNamespace string, kubeApi k8s.KubernetesApi) (pb.ApiClient, error)

func NewInternalClient added in v0.1.2

func NewInternalClient(kubernetesApiHost string) (pb.ApiClient, error)

func NewServer

func NewServer(
	addr string,
	prometheusClient promApi.Client,
	tapClient tapPb.TapClient,
	namespaceLister corelisters.NamespaceLister,
	deployLister applisters.DeploymentLister,
	replicaSetLister applisters.ReplicaSetLister,
	podLister corelisters.PodLister,
	controllerNamespace string,
	ignoredNamespaces []string,
) *http.Server

Types

type MockApi_TapClient added in v0.1.2

type MockApi_TapClient struct {
	TapEventsToReturn []common.TapEvent
	ErrorsToReturn    []error
	grpc.ClientStream
}

func (*MockApi_TapClient) Recv added in v0.1.2

func (a *MockApi_TapClient) Recv() (*common.TapEvent, error)

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
}

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 (*MockConduitApiClient) StatSummary added in v0.4.0

func (*MockConduitApiClient) Tap added in v0.1.2

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
	// contains filtered or unexported fields
}

func (*MockProm) LabelValues added in v0.4.0

func (m *MockProm) LabelValues(ctx context.Context, label string) (model.LabelValues, error)

func (*MockProm) Query added in v0.4.0

func (m *MockProm) Query(ctx context.Context, query string, ts time.Time) (model.Value, error)

satisfies v1.API

func (*MockProm) QueryRange added in v0.4.0

func (m *MockProm) QueryRange(ctx context.Context, query string, r v1.Range) (model.Value, error)

func (*MockProm) Series added in v0.4.0

func (m *MockProm) Series(ctx context.Context, matches []string, startTime time.Time, endTime time.Time) ([]model.LabelSet, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL