tps

package
v3.0.0-rc4-1 Latest Latest
Warning

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

Go to latest
Published: Nov 12, 2021 License: Apache-2.0 Imports: 8 Imported by: 4

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Filter

type Filter struct{}

Filter filters the requests by TPS *

  • if you wish to use the TpsLimiter, please add the configuration into your service provider configuration:
  • for example:
  • "UserProvider":
  • registry: "hangzhouzk"
  • protocol : "dubbo"
  • interface : "com.ikurento.user.UserProvider"
  • ... # other configuration
  • tps.limiter: "method-service", # it should be the name of limiter. if the value is 'default',
  • # the MethodServiceTpsLimiter will be used.
  • tps.limit.rejected.handler: "default", # optional, or the name of the implementation
  • if the value of 'tps.limiter' is nil or empty string, the tps filter will do nothing

func (*Filter) Invoke

func (t *Filter) Invoke(ctx context.Context, invoker protocol.Invoker, invocation protocol.Invocation) protocol.Result

Invoke gets the configured limter to impose TPS limiting

func (*Filter) OnResponse

OnResponse dummy process, returns the result directly

Directories

Path Synopsis
Package filter is a generated GoMock package.
Package filter is a generated GoMock package.
Package filter is a generated GoMock package.
Package filter is a generated GoMock package.

Jump to

Keyboard shortcuts

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