restapi

package
v1.0.0-beta.9 Latest Latest
Warning

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

Go to latest
Published: Jun 7, 2024 License: Apache-2.0 Imports: 8 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CompileRouteAsRegex

func CompileRouteAsRegex(route string) *regexp.Regexp

func CompileRoutesAsRegexes

func CompileRoutesAsRegexes(routes []string) ([]*regexp.Regexp, error)

Types

type DynamicProxy

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

func NewDynamicProxy

func NewDynamicProxy(e *echo.Echo, prefix string) *DynamicProxy

func (*DynamicProxy) AddGroup

func (p *DynamicProxy) AddGroup(prefix string) *echo.Group

func (*DynamicProxy) AddReverseProxy

func (p *DynamicProxy) AddReverseProxy(prefix string, host string, port uint32, path string) error

func (*DynamicProxy) RemoveReverseProxy

func (p *DynamicProxy) RemoveReverseProxy(prefix string)

type RestRouteManager

type RestRouteManager struct {
	syncutils.RWMutex
	// contains filtered or unexported fields
}

func NewRestRouteManager

func NewRestRouteManager(e *echo.Echo) *RestRouteManager

func (*RestRouteManager) AddProxyRoute

func (p *RestRouteManager) AddProxyRoute(route string, host string, port uint32, path string) error

AddProxyRoute adds a proxy route to the Routes endpoint and configures a remote proxy for this route.

func (*RestRouteManager) AddRoute

func (p *RestRouteManager) AddRoute(route string) *echo.Group

AddRoute adds a route to the Routes endpoint and returns group to be used to register endpoints.

func (*RestRouteManager) RemoveRoute

func (p *RestRouteManager) RemoveRoute(route string)

RemoveRoute removes a route from the Routes endpoint.

func (*RestRouteManager) Routes

func (p *RestRouteManager) Routes() []string

Jump to

Keyboard shortcuts

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