httpspec

package
v0.0.11 Latest Latest
Warning

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

Go to latest
Published: Jul 31, 2024 License: GPL-3.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type EndpointSpec

type EndpointSpec struct {
	Binding    *api.EndpointBinding
	SourceInfo SourceInfo
}

type Registry

type Registry struct {
	// contains filtered or unexported fields
}

func NewRegistry

func NewRegistry() *Registry

func (*Registry) Iterate

func (r *Registry) Iterate(cb func(fqmn string, spec EndpointSpec))

Iterate iterates over all registered endpoint specifications.

func (*Registry) LoadFromFile

func (r *Registry) LoadFromFile(filePath, protoPackage string) error

LoadFromFile loads a gateway config file for a proto file at filePath. if protoPackage is provided it will be used to convert relative selectors to absolute selectors.

func (*Registry) LoadFromService

func (r *Registry) LoadFromService(filePath, protoPackage string, service *descriptorpb.ServiceDescriptorProto) error

func (*Registry) LookupBinding

func (r *Registry) LookupBinding(selector string) (EndpointSpec, bool)

LookupBinding looks up endpoint bindings for a service method via a selector which is a FQMN.

type SourceInfo

type SourceInfo struct {
	Filename     string
	ProtoPackage string
}

Jump to

Keyboard shortcuts

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