servers

package
v0.6.0 Latest Latest
Warning

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

Go to latest
Published: Dec 4, 2020 License: Apache-2.0 Imports: 23 Imported by: 0

Documentation

Overview

Copyright 2018 ETH Zurich, Anapaya Systems

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Index

Constants

This section is empty.

Variables

View Source
var (
	PathsRequestsLabels              = []string{prom.LabelResult, prom.LabelDst}
	ASRequestsLabels                 = []string{prom.LabelResult}
	InterfacesRequestsLabels         = []string{prom.LabelResult}
	ServicesRequestsLabels           = []string{prom.LabelResult}
	InterfaceDownNotificationsLabels = []string{prom.LabelResult, prom.LabelSrc}
	LatencyLabels                    = []string{prom.LabelResult}
)

Labels used for metrics in the Metrics struct, those labels should be used for initialization.

Functions

This section is empty.

Types

type DaemonServer

type DaemonServer struct {
	Fetcher      fetcher.Fetcher
	TopoProvider topology.Provider
	RevCache     revcache.RevCache
	ASInspector  trust.Inspector

	Metrics Metrics
	// contains filtered or unexported fields
}

DaemonServer handles gRPC requests to the SCION daemon.

func (*DaemonServer) AS

AS serves the AS request.

func (*DaemonServer) Interfaces

Interfaces serves the interfaces request.

func (*DaemonServer) NotifyInterfaceDown

NotifyInterfaceDown notifies the server about an interface that is down.

func (*DaemonServer) Paths

Paths serves the paths request.

func (*DaemonServer) Services

Services serves the services request.

type Metrics

type Metrics struct {
	PathsRequests              RequestMetrics
	ASRequests                 RequestMetrics
	InterfacesRequests         RequestMetrics
	ServicesRequests           RequestMetrics
	InterfaceDownNotifications RequestMetrics
}

Metrics can be used to inject metrics into the SCION daemon server. Each field may be set individually.

type RequestMetrics

type RequestMetrics struct {
	Requests metrics.Counter
	Latency  metrics.Histogram
}

RequestMetrics contains the metrics for a given request.

Jump to

Keyboard shortcuts

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