throttlerservice

package
v0.17.6 Latest Latest
Warning

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

Go to latest
Published: Mar 14, 2024 License: Apache-2.0 Imports: 8 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

View Source
var File_throttlerservice_proto protoreflect.FileDescriptor
View Source
var Throttler_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "throttlerservice.Throttler",
	HandlerType: (*ThrottlerServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "MaxRates",
			Handler:    _Throttler_MaxRates_Handler,
		},
		{
			MethodName: "SetMaxRate",
			Handler:    _Throttler_SetMaxRate_Handler,
		},
		{
			MethodName: "GetConfiguration",
			Handler:    _Throttler_GetConfiguration_Handler,
		},
		{
			MethodName: "UpdateConfiguration",
			Handler:    _Throttler_UpdateConfiguration_Handler,
		},
		{
			MethodName: "ResetConfiguration",
			Handler:    _Throttler_ResetConfiguration_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "throttlerservice.proto",
}

Throttler_ServiceDesc is the grpc.ServiceDesc for Throttler service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterThrottlerServer

func RegisterThrottlerServer(s grpc.ServiceRegistrar, srv ThrottlerServer)

Types

type ThrottlerClient

type ThrottlerClient interface {
	// MaxRates returns the current max rate for each throttler of the process.
	MaxRates(ctx context.Context, in *throttlerdata.MaxRatesRequest, opts ...grpc.CallOption) (*throttlerdata.MaxRatesResponse, error)
	// SetMaxRate allows to change the current max rate for all throttlers
	// of the process.
	SetMaxRate(ctx context.Context, in *throttlerdata.SetMaxRateRequest, opts ...grpc.CallOption) (*throttlerdata.SetMaxRateResponse, error)
	// GetConfiguration returns the configuration of the MaxReplicationlag module
	// for the given throttler or all throttlers if "throttler_name" is empty.
	GetConfiguration(ctx context.Context, in *throttlerdata.GetConfigurationRequest, opts ...grpc.CallOption) (*throttlerdata.GetConfigurationResponse, error)
	// UpdateConfiguration (partially) updates the configuration of the
	// MaxReplicationlag module for the given throttler or all throttlers if
	// "throttler_name" is empty.
	// If "copy_zero_values" is true, fields with zero values will be copied
	// as well.
	UpdateConfiguration(ctx context.Context, in *throttlerdata.UpdateConfigurationRequest, opts ...grpc.CallOption) (*throttlerdata.UpdateConfigurationResponse, error)
	// ResetConfiguration resets the configuration of the MaxReplicationlag module
	// to the initial configuration for the given throttler or all throttlers if
	// "throttler_name" is empty.
	ResetConfiguration(ctx context.Context, in *throttlerdata.ResetConfigurationRequest, opts ...grpc.CallOption) (*throttlerdata.ResetConfigurationResponse, error)
}

ThrottlerClient is the client API for Throttler service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

func NewThrottlerClient

func NewThrottlerClient(cc grpc.ClientConnInterface) ThrottlerClient

type ThrottlerServer

type ThrottlerServer interface {
	// MaxRates returns the current max rate for each throttler of the process.
	MaxRates(context.Context, *throttlerdata.MaxRatesRequest) (*throttlerdata.MaxRatesResponse, error)
	// SetMaxRate allows to change the current max rate for all throttlers
	// of the process.
	SetMaxRate(context.Context, *throttlerdata.SetMaxRateRequest) (*throttlerdata.SetMaxRateResponse, error)
	// GetConfiguration returns the configuration of the MaxReplicationlag module
	// for the given throttler or all throttlers if "throttler_name" is empty.
	GetConfiguration(context.Context, *throttlerdata.GetConfigurationRequest) (*throttlerdata.GetConfigurationResponse, error)
	// UpdateConfiguration (partially) updates the configuration of the
	// MaxReplicationlag module for the given throttler or all throttlers if
	// "throttler_name" is empty.
	// If "copy_zero_values" is true, fields with zero values will be copied
	// as well.
	UpdateConfiguration(context.Context, *throttlerdata.UpdateConfigurationRequest) (*throttlerdata.UpdateConfigurationResponse, error)
	// ResetConfiguration resets the configuration of the MaxReplicationlag module
	// to the initial configuration for the given throttler or all throttlers if
	// "throttler_name" is empty.
	ResetConfiguration(context.Context, *throttlerdata.ResetConfigurationRequest) (*throttlerdata.ResetConfigurationResponse, error)
	// contains filtered or unexported methods
}

ThrottlerServer is the server API for Throttler service. All implementations must embed UnimplementedThrottlerServer for forward compatibility

type UnimplementedThrottlerServer

type UnimplementedThrottlerServer struct {
}

UnimplementedThrottlerServer must be embedded to have forward compatible implementations.

type UnsafeThrottlerServer added in v0.11.0

type UnsafeThrottlerServer interface {
	// contains filtered or unexported methods
}

UnsafeThrottlerServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to ThrottlerServer will result in compilation errors.

Jump to

Keyboard shortcuts

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