example

package
v0.0.0-...-8792969 Latest Latest
Warning

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

Go to latest
Published: Apr 15, 2024 License: MIT Imports: 10 Imported by: 0

Documentation

Overview

Code generated by servoc (gohttp plugin). DO NOT EDIT.

Code generated by servoc (gostruct plugin). DO NOT EDIT.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewEchoServiceHttpServer

func NewEchoServiceHttpServer(svc EchoService) *echo.Echo

func NewTelemetryServiceHttpServer

func NewTelemetryServiceHttpServer(svc TelemetryService) *echo.Echo

func RegisterEchoServiceRPCs

func RegisterEchoServiceRPCs(svc EchoService, srv *echo.Echo)

func RegisterEchoServiceRPCsGroup

func RegisterEchoServiceRPCsGroup(svc EchoService, srv *echo.Group)

func RegisterTelemetryServiceRPCs

func RegisterTelemetryServiceRPCs(svc TelemetryService, srv *echo.Echo)

func RegisterTelemetryServiceRPCsGroup

func RegisterTelemetryServiceRPCsGroup(svc TelemetryService, srv *echo.Group)

Types

type Binary

type Binary struct {
	Location URN   `json:"location"`
	Bits     []Bit `json:"bits"`
}

type Bit

type Bit bool

type EchoRequest

type EchoRequest struct {
	Message string `json:"message"`
}

type EchoResponse

type EchoResponse struct {
	Message string `json:"message"`
}

type EchoService

type EchoService interface {
	Echo(context.Context, *EchoRequest) (*EchoResponse, error)
}

func NewDelegatingEchoServiceHttpClient

func NewDelegatingEchoServiceHttpClient(baseUrl string, delegate *http.Client) EchoService

func NewEchoServiceHttpClient

func NewEchoServiceHttpClient(baseUrl string) EchoService

func NewEchoServiceTestHttpClient

func NewEchoServiceTestHttpClient(svc EchoService) EchoService

type Log

type Log struct {
	Labels map[string]string `json:"labels"`
	Value  string            `json:"value"`
}

type Metric

type Metric struct {
	Type   MetricType        `json:"type"`
	Name   string            `json:"name"`
	Labels map[string]string `json:"labels"`
	Value  float64           `json:"value"`
	At     time.Time         `json:"at"`
}

type MetricType

type MetricType string
const (
	MetricType_Counter MetricType = "COUNTER"
	MetricType_Gauge   MetricType = "GAUGE"
)

type Telemetry

type Telemetry struct {
	TelemetryType string  `json:"@type"`
	Log           *Log    `json:"log,omitempty"`
	Metric        *Metric `json:"metric,omitempty"`
}

type TelemetryService

type TelemetryService interface {
	Publish(context.Context, *Telemetry) error
}

func NewDelegatingTelemetryServiceHttpClient

func NewDelegatingTelemetryServiceHttpClient(baseUrl string, delegate *http.Client) TelemetryService

func NewTelemetryServiceHttpClient

func NewTelemetryServiceHttpClient(baseUrl string) TelemetryService

func NewTelemetryServiceTestHttpClient

func NewTelemetryServiceTestHttpClient(svc TelemetryService) TelemetryService

type URN

type URN string

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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