base

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Aug 15, 2024 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ConsumerRoot string = "/consumers/"
	PluginRoot   string = "/plugins/"
	ServiceRoot  string = "/services/"
	RouteRoot    string = "/routes/"
	AclRoot      string = "/acls/"
	UpstreamRoot string = "/upstreams/"
	HealthPath   string = "/health/"
	TargetPath   string = "/targets/"
)

Variables

View Source
var (
	ErrInvalidReq = errors.New("kongAdapter: invalid request")
)

Functions

This section is empty.

Types

type KongAdapterImpl

type KongAdapterImpl struct {
	KongAddr string
	Client   *http.Client
}

func (*KongAdapterImpl) AddPlugin

func (impl *KongAdapterImpl) AddPlugin(req *PluginReqDto) (*PluginRespDto, error)

func (*KongAdapterImpl) AddUpstreamTarget

func (impl *KongAdapterImpl) AddUpstreamTarget(upstreamId string, req *TargetDto) (*TargetDto, error)

func (*KongAdapterImpl) CheckPluginEnabled

func (impl *KongAdapterImpl) CheckPluginEnabled(pluginName string) (bool, error)

func (*KongAdapterImpl) CreateAclGroup

func (impl *KongAdapterImpl) CreateAclGroup(consumerId string, customId string) error

func (*KongAdapterImpl) CreateConsumer

func (impl *KongAdapterImpl) CreateConsumer(req *ConsumerReqDto) (*ConsumerRespDto, error)

func (*KongAdapterImpl) CreateCredential

func (impl *KongAdapterImpl) CreateCredential(req *CredentialReqDto) (*CredentialDto, error)

func (*KongAdapterImpl) CreateOrUpdatePlugin

func (impl *KongAdapterImpl) CreateOrUpdatePlugin(req *PluginReqDto) (*PluginRespDto, error)

func (*KongAdapterImpl) CreateOrUpdatePluginById

func (impl *KongAdapterImpl) CreateOrUpdatePluginById(req *PluginReqDto) (*PluginRespDto, error)

func (*KongAdapterImpl) CreateOrUpdateRoute

func (impl *KongAdapterImpl) CreateOrUpdateRoute(req *RouteReqDto) (*RouteRespDto, error)

func (*KongAdapterImpl) CreateOrUpdateService

func (impl *KongAdapterImpl) CreateOrUpdateService(req *ServiceReqDto) (*ServiceRespDto, error)

func (*KongAdapterImpl) CreateUpstream

func (impl *KongAdapterImpl) CreateUpstream(req *UpstreamDto) (*UpstreamDto, error)

func (*KongAdapterImpl) DeleteConsumer

func (impl *KongAdapterImpl) DeleteConsumer(id string) error

func (*KongAdapterImpl) DeleteCredential

func (impl *KongAdapterImpl) DeleteCredential(consumerId, pluginName, credentialId string) error

func (*KongAdapterImpl) DeletePluginIfExist

func (impl *KongAdapterImpl) DeletePluginIfExist(req *PluginReqDto) error

func (*KongAdapterImpl) DeleteRoute

func (impl *KongAdapterImpl) DeleteRoute(id string) error

func (*KongAdapterImpl) DeleteService

func (impl *KongAdapterImpl) DeleteService(id string) error

func (*KongAdapterImpl) DeleteUpstreamTarget

func (impl *KongAdapterImpl) DeleteUpstreamTarget(upstreamId, targetId string) error

func (*KongAdapterImpl) GatewayProviderExist

func (impl *KongAdapterImpl) GatewayProviderExist() bool

func (*KongAdapterImpl) GetCredentialList

func (impl *KongAdapterImpl) GetCredentialList(consumerId, pluginName string) (*CredentialListDto, error)

func (*KongAdapterImpl) GetPlugin

func (impl *KongAdapterImpl) GetPlugin(req *PluginReqDto) (*PluginRespDto, error)

func (*KongAdapterImpl) GetRoutes

func (impl *KongAdapterImpl) GetRoutes() ([]RouteRespDto, error)

func (*KongAdapterImpl) GetRoutesWithTag

func (impl *KongAdapterImpl) GetRoutesWithTag(tag string) ([]RouteRespDto, error)

func (*KongAdapterImpl) GetUpstreamStatus

func (impl *KongAdapterImpl) GetUpstreamStatus(upstreamId string) (*UpstreamStatusRespDto, error)

func (*KongAdapterImpl) GetVersion

func (impl *KongAdapterImpl) GetVersion() (string, error)

func (*KongAdapterImpl) PutPlugin

func (impl *KongAdapterImpl) PutPlugin(req *PluginReqDto) (*PluginRespDto, error)

func (*KongAdapterImpl) RemovePlugin

func (impl *KongAdapterImpl) RemovePlugin(id string) error

func (*KongAdapterImpl) TouchRouteOAuthMethod

func (impl *KongAdapterImpl) TouchRouteOAuthMethod(id string) error

func (*KongAdapterImpl) UpdatePlugin

func (impl *KongAdapterImpl) UpdatePlugin(req *PluginReqDto) (*PluginRespDto, error)

func (*KongAdapterImpl) UpdateRoute

func (impl *KongAdapterImpl) UpdateRoute(req *RouteReqDto) (*RouteRespDto, error)

Jump to

Keyboard shortcuts

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