testingconnect

package
v1.16.1-20240412200742... Latest Latest
Warning

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

Go to latest
Published: unknown License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// BenchmarkServiceUnaryCallProcedure is the fully-qualified name of the BenchmarkService's
	// UnaryCall RPC.
	BenchmarkServiceUnaryCallProcedure = "/grpc.testing.BenchmarkService/UnaryCall"
	// BenchmarkServiceStreamingCallProcedure is the fully-qualified name of the BenchmarkService's
	// StreamingCall RPC.
	BenchmarkServiceStreamingCallProcedure = "/grpc.testing.BenchmarkService/StreamingCall"
	// BenchmarkServiceStreamingFromClientProcedure is the fully-qualified name of the
	// BenchmarkService's StreamingFromClient RPC.
	BenchmarkServiceStreamingFromClientProcedure = "/grpc.testing.BenchmarkService/StreamingFromClient"
	// BenchmarkServiceStreamingFromServerProcedure is the fully-qualified name of the
	// BenchmarkService's StreamingFromServer RPC.
	BenchmarkServiceStreamingFromServerProcedure = "/grpc.testing.BenchmarkService/StreamingFromServer"
	// BenchmarkServiceStreamingBothWaysProcedure is the fully-qualified name of the BenchmarkService's
	// StreamingBothWays RPC.
	BenchmarkServiceStreamingBothWaysProcedure = "/grpc.testing.BenchmarkService/StreamingBothWays"
)

These constants are the fully-qualified names of the RPCs defined in this package. They're exposed at runtime as Spec.Procedure and as the final two segments of the HTTP route.

Note that these are different from the fully-qualified method names used by google.golang.org/protobuf/reflect/protoreflect. To convert from these constants to reflection-formatted method names, remove the leading slash and convert the remaining slash to a period.

View Source
const (
	// TestServiceName is the fully-qualified name of the TestService service.
	TestServiceName = "grpc.testing.TestService"
	// UnimplementedServiceName is the fully-qualified name of the UnimplementedService service.
	UnimplementedServiceName = "grpc.testing.UnimplementedService"
	// ReconnectServiceName is the fully-qualified name of the ReconnectService service.
	ReconnectServiceName = "grpc.testing.ReconnectService"
	// LoadBalancerStatsServiceName is the fully-qualified name of the LoadBalancerStatsService service.
	LoadBalancerStatsServiceName = "grpc.testing.LoadBalancerStatsService"
	// HookServiceName is the fully-qualified name of the HookService service.
	HookServiceName = "grpc.testing.HookService"
	// XdsUpdateHealthServiceName is the fully-qualified name of the XdsUpdateHealthService service.
	XdsUpdateHealthServiceName = "grpc.testing.XdsUpdateHealthService"
	// XdsUpdateClientConfigureServiceName is the fully-qualified name of the
	// XdsUpdateClientConfigureService service.
	XdsUpdateClientConfigureServiceName = "grpc.testing.XdsUpdateClientConfigureService"
)
View Source
const (
	// TestServiceEmptyCallProcedure is the fully-qualified name of the TestService's EmptyCall RPC.
	TestServiceEmptyCallProcedure = "/grpc.testing.TestService/EmptyCall"
	// TestServiceUnaryCallProcedure is the fully-qualified name of the TestService's UnaryCall RPC.
	TestServiceUnaryCallProcedure = "/grpc.testing.TestService/UnaryCall"
	// TestServiceCacheableUnaryCallProcedure is the fully-qualified name of the TestService's
	// CacheableUnaryCall RPC.
	TestServiceCacheableUnaryCallProcedure = "/grpc.testing.TestService/CacheableUnaryCall"
	// TestServiceStreamingOutputCallProcedure is the fully-qualified name of the TestService's
	// StreamingOutputCall RPC.
	TestServiceStreamingOutputCallProcedure = "/grpc.testing.TestService/StreamingOutputCall"
	// TestServiceStreamingInputCallProcedure is the fully-qualified name of the TestService's
	// StreamingInputCall RPC.
	TestServiceStreamingInputCallProcedure = "/grpc.testing.TestService/StreamingInputCall"
	// TestServiceFullDuplexCallProcedure is the fully-qualified name of the TestService's
	// FullDuplexCall RPC.
	TestServiceFullDuplexCallProcedure = "/grpc.testing.TestService/FullDuplexCall"
	// TestServiceHalfDuplexCallProcedure is the fully-qualified name of the TestService's
	// HalfDuplexCall RPC.
	TestServiceHalfDuplexCallProcedure = "/grpc.testing.TestService/HalfDuplexCall"
	// TestServiceUnimplementedCallProcedure is the fully-qualified name of the TestService's
	// UnimplementedCall RPC.
	TestServiceUnimplementedCallProcedure = "/grpc.testing.TestService/UnimplementedCall"
	// UnimplementedServiceUnimplementedCallProcedure is the fully-qualified name of the
	// UnimplementedService's UnimplementedCall RPC.
	UnimplementedServiceUnimplementedCallProcedure = "/grpc.testing.UnimplementedService/UnimplementedCall"
	// ReconnectServiceStartProcedure is the fully-qualified name of the ReconnectService's Start RPC.
	ReconnectServiceStartProcedure = "/grpc.testing.ReconnectService/Start"
	// ReconnectServiceStopProcedure is the fully-qualified name of the ReconnectService's Stop RPC.
	ReconnectServiceStopProcedure = "/grpc.testing.ReconnectService/Stop"
	// LoadBalancerStatsServiceGetClientStatsProcedure is the fully-qualified name of the
	// LoadBalancerStatsService's GetClientStats RPC.
	LoadBalancerStatsServiceGetClientStatsProcedure = "/grpc.testing.LoadBalancerStatsService/GetClientStats"
	// LoadBalancerStatsServiceGetClientAccumulatedStatsProcedure is the fully-qualified name of the
	// LoadBalancerStatsService's GetClientAccumulatedStats RPC.
	LoadBalancerStatsServiceGetClientAccumulatedStatsProcedure = "/grpc.testing.LoadBalancerStatsService/GetClientAccumulatedStats"
	// HookServiceHookProcedure is the fully-qualified name of the HookService's Hook RPC.
	HookServiceHookProcedure = "/grpc.testing.HookService/Hook"
	// HookServiceSetReturnStatusProcedure is the fully-qualified name of the HookService's
	// SetReturnStatus RPC.
	HookServiceSetReturnStatusProcedure = "/grpc.testing.HookService/SetReturnStatus"
	// HookServiceClearReturnStatusProcedure is the fully-qualified name of the HookService's
	// ClearReturnStatus RPC.
	HookServiceClearReturnStatusProcedure = "/grpc.testing.HookService/ClearReturnStatus"
	// XdsUpdateHealthServiceSetServingProcedure is the fully-qualified name of the
	// XdsUpdateHealthService's SetServing RPC.
	XdsUpdateHealthServiceSetServingProcedure = "/grpc.testing.XdsUpdateHealthService/SetServing"
	// XdsUpdateHealthServiceSetNotServingProcedure is the fully-qualified name of the
	// XdsUpdateHealthService's SetNotServing RPC.
	XdsUpdateHealthServiceSetNotServingProcedure = "/grpc.testing.XdsUpdateHealthService/SetNotServing"
	// XdsUpdateHealthServiceSendHookRequestProcedure is the fully-qualified name of the
	// XdsUpdateHealthService's SendHookRequest RPC.
	XdsUpdateHealthServiceSendHookRequestProcedure = "/grpc.testing.XdsUpdateHealthService/SendHookRequest"
	// XdsUpdateClientConfigureServiceConfigureProcedure is the fully-qualified name of the
	// XdsUpdateClientConfigureService's Configure RPC.
	XdsUpdateClientConfigureServiceConfigureProcedure = "/grpc.testing.XdsUpdateClientConfigureService/Configure"
)

These constants are the fully-qualified names of the RPCs defined in this package. They're exposed at runtime as Spec.Procedure and as the final two segments of the HTTP route.

Note that these are different from the fully-qualified method names used by google.golang.org/protobuf/reflect/protoreflect. To convert from these constants to reflection-formatted method names, remove the leading slash and convert the remaining slash to a period.

View Source
const (
	// WorkerServiceRunServerProcedure is the fully-qualified name of the WorkerService's RunServer RPC.
	WorkerServiceRunServerProcedure = "/grpc.testing.WorkerService/RunServer"
	// WorkerServiceRunClientProcedure is the fully-qualified name of the WorkerService's RunClient RPC.
	WorkerServiceRunClientProcedure = "/grpc.testing.WorkerService/RunClient"
	// WorkerServiceCoreCountProcedure is the fully-qualified name of the WorkerService's CoreCount RPC.
	WorkerServiceCoreCountProcedure = "/grpc.testing.WorkerService/CoreCount"
	// WorkerServiceQuitWorkerProcedure is the fully-qualified name of the WorkerService's QuitWorker
	// RPC.
	WorkerServiceQuitWorkerProcedure = "/grpc.testing.WorkerService/QuitWorker"
)

These constants are the fully-qualified names of the RPCs defined in this package. They're exposed at runtime as Spec.Procedure and as the final two segments of the HTTP route.

Note that these are different from the fully-qualified method names used by google.golang.org/protobuf/reflect/protoreflect. To convert from these constants to reflection-formatted method names, remove the leading slash and convert the remaining slash to a period.

View Source
const (
	// BenchmarkServiceName is the fully-qualified name of the BenchmarkService service.
	BenchmarkServiceName = "grpc.testing.BenchmarkService"
)
View Source
const (
	// ReportQpsScenarioServiceName is the fully-qualified name of the ReportQpsScenarioService service.
	ReportQpsScenarioServiceName = "grpc.testing.ReportQpsScenarioService"
)
View Source
const (
	// ReportQpsScenarioServiceReportScenarioProcedure is the fully-qualified name of the
	// ReportQpsScenarioService's ReportScenario RPC.
	ReportQpsScenarioServiceReportScenarioProcedure = "/grpc.testing.ReportQpsScenarioService/ReportScenario"
)

These constants are the fully-qualified names of the RPCs defined in this package. They're exposed at runtime as Spec.Procedure and as the final two segments of the HTTP route.

Note that these are different from the fully-qualified method names used by google.golang.org/protobuf/reflect/protoreflect. To convert from these constants to reflection-formatted method names, remove the leading slash and convert the remaining slash to a period.

View Source
const (
	// WorkerServiceName is the fully-qualified name of the WorkerService service.
	WorkerServiceName = "grpc.testing.WorkerService"
)

Variables

This section is empty.

Functions

func NewBenchmarkServiceHandler

func NewBenchmarkServiceHandler(svc BenchmarkServiceHandler, opts ...connect.HandlerOption) (string, http.Handler)

NewBenchmarkServiceHandler builds an HTTP handler from the service implementation. It returns the path on which to mount the handler and the handler itself.

By default, handlers support the Connect, gRPC, and gRPC-Web protocols with the binary Protobuf and JSON codecs. They also support gzip compression.

func NewHookServiceHandler

func NewHookServiceHandler(svc HookServiceHandler, opts ...connect.HandlerOption) (string, http.Handler)

NewHookServiceHandler builds an HTTP handler from the service implementation. It returns the path on which to mount the handler and the handler itself.

By default, handlers support the Connect, gRPC, and gRPC-Web protocols with the binary Protobuf and JSON codecs. They also support gzip compression.

func NewLoadBalancerStatsServiceHandler

func NewLoadBalancerStatsServiceHandler(svc LoadBalancerStatsServiceHandler, opts ...connect.HandlerOption) (string, http.Handler)

NewLoadBalancerStatsServiceHandler builds an HTTP handler from the service implementation. It returns the path on which to mount the handler and the handler itself.

By default, handlers support the Connect, gRPC, and gRPC-Web protocols with the binary Protobuf and JSON codecs. They also support gzip compression.

func NewReconnectServiceHandler

func NewReconnectServiceHandler(svc ReconnectServiceHandler, opts ...connect.HandlerOption) (string, http.Handler)

NewReconnectServiceHandler builds an HTTP handler from the service implementation. It returns the path on which to mount the handler and the handler itself.

By default, handlers support the Connect, gRPC, and gRPC-Web protocols with the binary Protobuf and JSON codecs. They also support gzip compression.

func NewReportQpsScenarioServiceHandler

func NewReportQpsScenarioServiceHandler(svc ReportQpsScenarioServiceHandler, opts ...connect.HandlerOption) (string, http.Handler)

NewReportQpsScenarioServiceHandler builds an HTTP handler from the service implementation. It returns the path on which to mount the handler and the handler itself.

By default, handlers support the Connect, gRPC, and gRPC-Web protocols with the binary Protobuf and JSON codecs. They also support gzip compression.

func NewTestServiceHandler

func NewTestServiceHandler(svc TestServiceHandler, opts ...connect.HandlerOption) (string, http.Handler)

NewTestServiceHandler builds an HTTP handler from the service implementation. It returns the path on which to mount the handler and the handler itself.

By default, handlers support the Connect, gRPC, and gRPC-Web protocols with the binary Protobuf and JSON codecs. They also support gzip compression.

func NewUnimplementedServiceHandler

func NewUnimplementedServiceHandler(svc UnimplementedServiceHandler, opts ...connect.HandlerOption) (string, http.Handler)

NewUnimplementedServiceHandler builds an HTTP handler from the service implementation. It returns the path on which to mount the handler and the handler itself.

By default, handlers support the Connect, gRPC, and gRPC-Web protocols with the binary Protobuf and JSON codecs. They also support gzip compression.

func NewWorkerServiceHandler

func NewWorkerServiceHandler(svc WorkerServiceHandler, opts ...connect.HandlerOption) (string, http.Handler)

NewWorkerServiceHandler builds an HTTP handler from the service implementation. It returns the path on which to mount the handler and the handler itself.

By default, handlers support the Connect, gRPC, and gRPC-Web protocols with the binary Protobuf and JSON codecs. They also support gzip compression.

func NewXdsUpdateClientConfigureServiceHandler

func NewXdsUpdateClientConfigureServiceHandler(svc XdsUpdateClientConfigureServiceHandler, opts ...connect.HandlerOption) (string, http.Handler)

NewXdsUpdateClientConfigureServiceHandler builds an HTTP handler from the service implementation. It returns the path on which to mount the handler and the handler itself.

By default, handlers support the Connect, gRPC, and gRPC-Web protocols with the binary Protobuf and JSON codecs. They also support gzip compression.

func NewXdsUpdateHealthServiceHandler

func NewXdsUpdateHealthServiceHandler(svc XdsUpdateHealthServiceHandler, opts ...connect.HandlerOption) (string, http.Handler)

NewXdsUpdateHealthServiceHandler builds an HTTP handler from the service implementation. It returns the path on which to mount the handler and the handler itself.

By default, handlers support the Connect, gRPC, and gRPC-Web protocols with the binary Protobuf and JSON codecs. They also support gzip compression.

Types

type BenchmarkServiceClient

type BenchmarkServiceClient interface {
	// One request followed by one response.
	// The server returns the client payload as-is.
	UnaryCall(context.Context, *connect.Request[testing.SimpleRequest]) (*connect.Response[testing.SimpleResponse], error)
	// Repeated sequence of one request followed by one response.
	// Should be called streaming ping-pong
	// The server returns the client payload as-is on each response
	StreamingCall(context.Context) *connect.BidiStreamForClient[testing.SimpleRequest, testing.SimpleResponse]
	// Single-sided unbounded streaming from client to server
	// The server returns the client payload as-is once the client does WritesDone
	StreamingFromClient(context.Context) *connect.ClientStreamForClient[testing.SimpleRequest, testing.SimpleResponse]
	// Single-sided unbounded streaming from server to client
	// The server repeatedly returns the client payload as-is
	StreamingFromServer(context.Context, *connect.Request[testing.SimpleRequest]) (*connect.ServerStreamForClient[testing.SimpleResponse], error)
	// Two-sided unbounded streaming between server to client
	// Both sides send the content of their own choice to the other
	StreamingBothWays(context.Context) *connect.BidiStreamForClient[testing.SimpleRequest, testing.SimpleResponse]
}

BenchmarkServiceClient is a client for the grpc.testing.BenchmarkService service.

func NewBenchmarkServiceClient

func NewBenchmarkServiceClient(httpClient connect.HTTPClient, baseURL string, opts ...connect.ClientOption) BenchmarkServiceClient

NewBenchmarkServiceClient constructs a client for the grpc.testing.BenchmarkService service. By default, it uses the Connect protocol with the binary Protobuf Codec, asks for gzipped responses, and sends uncompressed requests. To use the gRPC or gRPC-Web protocols, supply the connect.WithGRPC() or connect.WithGRPCWeb() options.

The URL supplied here should be the base URL for the Connect or gRPC server (for example, http://api.acme.com or https://acme.com/grpc).

type BenchmarkServiceHandler

type BenchmarkServiceHandler interface {
	// One request followed by one response.
	// The server returns the client payload as-is.
	UnaryCall(context.Context, *connect.Request[testing.SimpleRequest]) (*connect.Response[testing.SimpleResponse], error)
	// Repeated sequence of one request followed by one response.
	// Should be called streaming ping-pong
	// The server returns the client payload as-is on each response
	StreamingCall(context.Context, *connect.BidiStream[testing.SimpleRequest, testing.SimpleResponse]) error
	// Single-sided unbounded streaming from client to server
	// The server returns the client payload as-is once the client does WritesDone
	StreamingFromClient(context.Context, *connect.ClientStream[testing.SimpleRequest]) (*connect.Response[testing.SimpleResponse], error)
	// Single-sided unbounded streaming from server to client
	// The server repeatedly returns the client payload as-is
	StreamingFromServer(context.Context, *connect.Request[testing.SimpleRequest], *connect.ServerStream[testing.SimpleResponse]) error
	// Two-sided unbounded streaming between server to client
	// Both sides send the content of their own choice to the other
	StreamingBothWays(context.Context, *connect.BidiStream[testing.SimpleRequest, testing.SimpleResponse]) error
}

BenchmarkServiceHandler is an implementation of the grpc.testing.BenchmarkService service.

type HookServiceClient

type HookServiceClient interface {
	// Sends a request that will "hang" until the return status is set by a call
	// to a SetReturnStatus
	Hook(context.Context, *connect.Request[testing.Empty]) (*connect.Response[testing.Empty], error)
	// Sets a return status for pending and upcoming calls to Hook
	SetReturnStatus(context.Context, *connect.Request[testing.SetReturnStatusRequest]) (*connect.Response[testing.Empty], error)
	// Clears the return status. Incoming calls to Hook will "hang"
	ClearReturnStatus(context.Context, *connect.Request[testing.Empty]) (*connect.Response[testing.Empty], error)
}

HookServiceClient is a client for the grpc.testing.HookService service.

func NewHookServiceClient

func NewHookServiceClient(httpClient connect.HTTPClient, baseURL string, opts ...connect.ClientOption) HookServiceClient

NewHookServiceClient constructs a client for the grpc.testing.HookService service. By default, it uses the Connect protocol with the binary Protobuf Codec, asks for gzipped responses, and sends uncompressed requests. To use the gRPC or gRPC-Web protocols, supply the connect.WithGRPC() or connect.WithGRPCWeb() options.

The URL supplied here should be the base URL for the Connect or gRPC server (for example, http://api.acme.com or https://acme.com/grpc).

type HookServiceHandler

type HookServiceHandler interface {
	// Sends a request that will "hang" until the return status is set by a call
	// to a SetReturnStatus
	Hook(context.Context, *connect.Request[testing.Empty]) (*connect.Response[testing.Empty], error)
	// Sets a return status for pending and upcoming calls to Hook
	SetReturnStatus(context.Context, *connect.Request[testing.SetReturnStatusRequest]) (*connect.Response[testing.Empty], error)
	// Clears the return status. Incoming calls to Hook will "hang"
	ClearReturnStatus(context.Context, *connect.Request[testing.Empty]) (*connect.Response[testing.Empty], error)
}

HookServiceHandler is an implementation of the grpc.testing.HookService service.

type LoadBalancerStatsServiceClient

type LoadBalancerStatsServiceClient interface {
	// Gets the backend distribution for RPCs sent by a test client.
	GetClientStats(context.Context, *connect.Request[testing.LoadBalancerStatsRequest]) (*connect.Response[testing.LoadBalancerStatsResponse], error)
	// Gets the accumulated stats for RPCs sent by a test client.
	GetClientAccumulatedStats(context.Context, *connect.Request[testing.LoadBalancerAccumulatedStatsRequest]) (*connect.Response[testing.LoadBalancerAccumulatedStatsResponse], error)
}

LoadBalancerStatsServiceClient is a client for the grpc.testing.LoadBalancerStatsService service.

func NewLoadBalancerStatsServiceClient

func NewLoadBalancerStatsServiceClient(httpClient connect.HTTPClient, baseURL string, opts ...connect.ClientOption) LoadBalancerStatsServiceClient

NewLoadBalancerStatsServiceClient constructs a client for the grpc.testing.LoadBalancerStatsService service. By default, it uses the Connect protocol with the binary Protobuf Codec, asks for gzipped responses, and sends uncompressed requests. To use the gRPC or gRPC-Web protocols, supply the connect.WithGRPC() or connect.WithGRPCWeb() options.

The URL supplied here should be the base URL for the Connect or gRPC server (for example, http://api.acme.com or https://acme.com/grpc).

type LoadBalancerStatsServiceHandler

type LoadBalancerStatsServiceHandler interface {
	// Gets the backend distribution for RPCs sent by a test client.
	GetClientStats(context.Context, *connect.Request[testing.LoadBalancerStatsRequest]) (*connect.Response[testing.LoadBalancerStatsResponse], error)
	// Gets the accumulated stats for RPCs sent by a test client.
	GetClientAccumulatedStats(context.Context, *connect.Request[testing.LoadBalancerAccumulatedStatsRequest]) (*connect.Response[testing.LoadBalancerAccumulatedStatsResponse], error)
}

LoadBalancerStatsServiceHandler is an implementation of the grpc.testing.LoadBalancerStatsService service.

type ReconnectServiceClient

ReconnectServiceClient is a client for the grpc.testing.ReconnectService service.

func NewReconnectServiceClient

func NewReconnectServiceClient(httpClient connect.HTTPClient, baseURL string, opts ...connect.ClientOption) ReconnectServiceClient

NewReconnectServiceClient constructs a client for the grpc.testing.ReconnectService service. By default, it uses the Connect protocol with the binary Protobuf Codec, asks for gzipped responses, and sends uncompressed requests. To use the gRPC or gRPC-Web protocols, supply the connect.WithGRPC() or connect.WithGRPCWeb() options.

The URL supplied here should be the base URL for the Connect or gRPC server (for example, http://api.acme.com or https://acme.com/grpc).

type ReconnectServiceHandler

ReconnectServiceHandler is an implementation of the grpc.testing.ReconnectService service.

type ReportQpsScenarioServiceClient

type ReportQpsScenarioServiceClient interface {
	// Report results of a QPS test benchmark scenario.
	ReportScenario(context.Context, *connect.Request[testing.ScenarioResult]) (*connect.Response[testing.Void], error)
}

ReportQpsScenarioServiceClient is a client for the grpc.testing.ReportQpsScenarioService service.

func NewReportQpsScenarioServiceClient

func NewReportQpsScenarioServiceClient(httpClient connect.HTTPClient, baseURL string, opts ...connect.ClientOption) ReportQpsScenarioServiceClient

NewReportQpsScenarioServiceClient constructs a client for the grpc.testing.ReportQpsScenarioService service. By default, it uses the Connect protocol with the binary Protobuf Codec, asks for gzipped responses, and sends uncompressed requests. To use the gRPC or gRPC-Web protocols, supply the connect.WithGRPC() or connect.WithGRPCWeb() options.

The URL supplied here should be the base URL for the Connect or gRPC server (for example, http://api.acme.com or https://acme.com/grpc).

type ReportQpsScenarioServiceHandler

type ReportQpsScenarioServiceHandler interface {
	// Report results of a QPS test benchmark scenario.
	ReportScenario(context.Context, *connect.Request[testing.ScenarioResult]) (*connect.Response[testing.Void], error)
}

ReportQpsScenarioServiceHandler is an implementation of the grpc.testing.ReportQpsScenarioService service.

type TestServiceClient

type TestServiceClient interface {
	// One empty request followed by one empty response.
	EmptyCall(context.Context, *connect.Request[testing.Empty]) (*connect.Response[testing.Empty], error)
	// One request followed by one response.
	UnaryCall(context.Context, *connect.Request[testing.SimpleRequest]) (*connect.Response[testing.SimpleResponse], error)
	// One request followed by one response. Response has cache control
	// headers set such that a caching HTTP proxy (such as GFE) can
	// satisfy subsequent requests.
	CacheableUnaryCall(context.Context, *connect.Request[testing.SimpleRequest]) (*connect.Response[testing.SimpleResponse], error)
	// One request followed by a sequence of responses (streamed download).
	// The server returns the payload with client desired type and sizes.
	StreamingOutputCall(context.Context, *connect.Request[testing.StreamingOutputCallRequest]) (*connect.ServerStreamForClient[testing.StreamingOutputCallResponse], error)
	// A sequence of requests followed by one response (streamed upload).
	// The server returns the aggregated size of client payload as the result.
	StreamingInputCall(context.Context) *connect.ClientStreamForClient[testing.StreamingInputCallRequest, testing.StreamingInputCallResponse]
	// A sequence of requests with each request served by the server immediately.
	// As one request could lead to multiple responses, this interface
	// demonstrates the idea of full duplexing.
	FullDuplexCall(context.Context) *connect.BidiStreamForClient[testing.StreamingOutputCallRequest, testing.StreamingOutputCallResponse]
	// A sequence of requests followed by a sequence of responses.
	// The server buffers all the client requests and then serves them in order. A
	// stream of responses are returned to the client when the server starts with
	// first request.
	HalfDuplexCall(context.Context) *connect.BidiStreamForClient[testing.StreamingOutputCallRequest, testing.StreamingOutputCallResponse]
	// The test server will not implement this method. It will be used
	// to test the behavior when clients call unimplemented methods.
	UnimplementedCall(context.Context, *connect.Request[testing.Empty]) (*connect.Response[testing.Empty], error)
}

TestServiceClient is a client for the grpc.testing.TestService service.

func NewTestServiceClient

func NewTestServiceClient(httpClient connect.HTTPClient, baseURL string, opts ...connect.ClientOption) TestServiceClient

NewTestServiceClient constructs a client for the grpc.testing.TestService service. By default, it uses the Connect protocol with the binary Protobuf Codec, asks for gzipped responses, and sends uncompressed requests. To use the gRPC or gRPC-Web protocols, supply the connect.WithGRPC() or connect.WithGRPCWeb() options.

The URL supplied here should be the base URL for the Connect or gRPC server (for example, http://api.acme.com or https://acme.com/grpc).

type TestServiceHandler

type TestServiceHandler interface {
	// One empty request followed by one empty response.
	EmptyCall(context.Context, *connect.Request[testing.Empty]) (*connect.Response[testing.Empty], error)
	// One request followed by one response.
	UnaryCall(context.Context, *connect.Request[testing.SimpleRequest]) (*connect.Response[testing.SimpleResponse], error)
	// One request followed by one response. Response has cache control
	// headers set such that a caching HTTP proxy (such as GFE) can
	// satisfy subsequent requests.
	CacheableUnaryCall(context.Context, *connect.Request[testing.SimpleRequest]) (*connect.Response[testing.SimpleResponse], error)
	// One request followed by a sequence of responses (streamed download).
	// The server returns the payload with client desired type and sizes.
	StreamingOutputCall(context.Context, *connect.Request[testing.StreamingOutputCallRequest], *connect.ServerStream[testing.StreamingOutputCallResponse]) error
	// A sequence of requests followed by one response (streamed upload).
	// The server returns the aggregated size of client payload as the result.
	StreamingInputCall(context.Context, *connect.ClientStream[testing.StreamingInputCallRequest]) (*connect.Response[testing.StreamingInputCallResponse], error)
	// A sequence of requests with each request served by the server immediately.
	// As one request could lead to multiple responses, this interface
	// demonstrates the idea of full duplexing.
	FullDuplexCall(context.Context, *connect.BidiStream[testing.StreamingOutputCallRequest, testing.StreamingOutputCallResponse]) error
	// A sequence of requests followed by a sequence of responses.
	// The server buffers all the client requests and then serves them in order. A
	// stream of responses are returned to the client when the server starts with
	// first request.
	HalfDuplexCall(context.Context, *connect.BidiStream[testing.StreamingOutputCallRequest, testing.StreamingOutputCallResponse]) error
	// The test server will not implement this method. It will be used
	// to test the behavior when clients call unimplemented methods.
	UnimplementedCall(context.Context, *connect.Request[testing.Empty]) (*connect.Response[testing.Empty], error)
}

TestServiceHandler is an implementation of the grpc.testing.TestService service.

type UnimplementedBenchmarkServiceHandler

type UnimplementedBenchmarkServiceHandler struct{}

UnimplementedBenchmarkServiceHandler returns CodeUnimplemented from all methods.

func (UnimplementedBenchmarkServiceHandler) StreamingBothWays

func (UnimplementedBenchmarkServiceHandler) StreamingCall

func (UnimplementedBenchmarkServiceHandler) StreamingFromClient

func (UnimplementedBenchmarkServiceHandler) StreamingFromServer

func (UnimplementedBenchmarkServiceHandler) UnaryCall

type UnimplementedHookServiceHandler

type UnimplementedHookServiceHandler struct{}

UnimplementedHookServiceHandler returns CodeUnimplemented from all methods.

func (UnimplementedHookServiceHandler) ClearReturnStatus

func (UnimplementedHookServiceHandler) Hook

func (UnimplementedHookServiceHandler) SetReturnStatus

type UnimplementedLoadBalancerStatsServiceHandler

type UnimplementedLoadBalancerStatsServiceHandler struct{}

UnimplementedLoadBalancerStatsServiceHandler returns CodeUnimplemented from all methods.

func (UnimplementedLoadBalancerStatsServiceHandler) GetClientAccumulatedStats

func (UnimplementedLoadBalancerStatsServiceHandler) GetClientStats

type UnimplementedReconnectServiceHandler

type UnimplementedReconnectServiceHandler struct{}

UnimplementedReconnectServiceHandler returns CodeUnimplemented from all methods.

func (UnimplementedReconnectServiceHandler) Start

func (UnimplementedReconnectServiceHandler) Stop

type UnimplementedReportQpsScenarioServiceHandler

type UnimplementedReportQpsScenarioServiceHandler struct{}

UnimplementedReportQpsScenarioServiceHandler returns CodeUnimplemented from all methods.

func (UnimplementedReportQpsScenarioServiceHandler) ReportScenario

type UnimplementedServiceClient

type UnimplementedServiceClient interface {
	// A call that no server should implement
	UnimplementedCall(context.Context, *connect.Request[testing.Empty]) (*connect.Response[testing.Empty], error)
}

UnimplementedServiceClient is a client for the grpc.testing.UnimplementedService service.

func NewUnimplementedServiceClient

func NewUnimplementedServiceClient(httpClient connect.HTTPClient, baseURL string, opts ...connect.ClientOption) UnimplementedServiceClient

NewUnimplementedServiceClient constructs a client for the grpc.testing.UnimplementedService service. By default, it uses the Connect protocol with the binary Protobuf Codec, asks for gzipped responses, and sends uncompressed requests. To use the gRPC or gRPC-Web protocols, supply the connect.WithGRPC() or connect.WithGRPCWeb() options.

The URL supplied here should be the base URL for the Connect or gRPC server (for example, http://api.acme.com or https://acme.com/grpc).

type UnimplementedServiceHandler

type UnimplementedServiceHandler interface {
	// A call that no server should implement
	UnimplementedCall(context.Context, *connect.Request[testing.Empty]) (*connect.Response[testing.Empty], error)
}

UnimplementedServiceHandler is an implementation of the grpc.testing.UnimplementedService service.

type UnimplementedTestServiceHandler

type UnimplementedTestServiceHandler struct{}

UnimplementedTestServiceHandler returns CodeUnimplemented from all methods.

func (UnimplementedTestServiceHandler) CacheableUnaryCall

func (UnimplementedTestServiceHandler) EmptyCall

func (UnimplementedTestServiceHandler) FullDuplexCall

func (UnimplementedTestServiceHandler) HalfDuplexCall

func (UnimplementedTestServiceHandler) StreamingInputCall

func (UnimplementedTestServiceHandler) StreamingOutputCall

func (UnimplementedTestServiceHandler) UnaryCall

func (UnimplementedTestServiceHandler) UnimplementedCall

type UnimplementedUnimplementedServiceHandler

type UnimplementedUnimplementedServiceHandler struct{}

UnimplementedUnimplementedServiceHandler returns CodeUnimplemented from all methods.

func (UnimplementedUnimplementedServiceHandler) UnimplementedCall

type UnimplementedWorkerServiceHandler

type UnimplementedWorkerServiceHandler struct{}

UnimplementedWorkerServiceHandler returns CodeUnimplemented from all methods.

func (UnimplementedWorkerServiceHandler) CoreCount

func (UnimplementedWorkerServiceHandler) QuitWorker

func (UnimplementedWorkerServiceHandler) RunClient

func (UnimplementedWorkerServiceHandler) RunServer

type UnimplementedXdsUpdateClientConfigureServiceHandler

type UnimplementedXdsUpdateClientConfigureServiceHandler struct{}

UnimplementedXdsUpdateClientConfigureServiceHandler returns CodeUnimplemented from all methods.

func (UnimplementedXdsUpdateClientConfigureServiceHandler) Configure

type UnimplementedXdsUpdateHealthServiceHandler

type UnimplementedXdsUpdateHealthServiceHandler struct{}

UnimplementedXdsUpdateHealthServiceHandler returns CodeUnimplemented from all methods.

func (UnimplementedXdsUpdateHealthServiceHandler) SendHookRequest

func (UnimplementedXdsUpdateHealthServiceHandler) SetNotServing

func (UnimplementedXdsUpdateHealthServiceHandler) SetServing

type WorkerServiceClient

type WorkerServiceClient interface {
	// Start server with specified workload.
	// First request sent specifies the ServerConfig followed by ServerStatus
	// response. After that, a "Mark" can be sent anytime to request the latest
	// stats. Closing the stream will initiate shutdown of the test server
	// and once the shutdown has finished, the OK status is sent to terminate
	// this RPC.
	RunServer(context.Context) *connect.BidiStreamForClient[testing.ServerArgs, testing.ServerStatus]
	// Start client with specified workload.
	// First request sent specifies the ClientConfig followed by ClientStatus
	// response. After that, a "Mark" can be sent anytime to request the latest
	// stats. Closing the stream will initiate shutdown of the test client
	// and once the shutdown has finished, the OK status is sent to terminate
	// this RPC.
	RunClient(context.Context) *connect.BidiStreamForClient[testing.ClientArgs, testing.ClientStatus]
	// Just return the core count - unary call
	CoreCount(context.Context, *connect.Request[testing.CoreRequest]) (*connect.Response[testing.CoreResponse], error)
	// Quit this worker
	QuitWorker(context.Context, *connect.Request[testing.Void]) (*connect.Response[testing.Void], error)
}

WorkerServiceClient is a client for the grpc.testing.WorkerService service.

func NewWorkerServiceClient

func NewWorkerServiceClient(httpClient connect.HTTPClient, baseURL string, opts ...connect.ClientOption) WorkerServiceClient

NewWorkerServiceClient constructs a client for the grpc.testing.WorkerService service. By default, it uses the Connect protocol with the binary Protobuf Codec, asks for gzipped responses, and sends uncompressed requests. To use the gRPC or gRPC-Web protocols, supply the connect.WithGRPC() or connect.WithGRPCWeb() options.

The URL supplied here should be the base URL for the Connect or gRPC server (for example, http://api.acme.com or https://acme.com/grpc).

type WorkerServiceHandler

type WorkerServiceHandler interface {
	// Start server with specified workload.
	// First request sent specifies the ServerConfig followed by ServerStatus
	// response. After that, a "Mark" can be sent anytime to request the latest
	// stats. Closing the stream will initiate shutdown of the test server
	// and once the shutdown has finished, the OK status is sent to terminate
	// this RPC.
	RunServer(context.Context, *connect.BidiStream[testing.ServerArgs, testing.ServerStatus]) error
	// Start client with specified workload.
	// First request sent specifies the ClientConfig followed by ClientStatus
	// response. After that, a "Mark" can be sent anytime to request the latest
	// stats. Closing the stream will initiate shutdown of the test client
	// and once the shutdown has finished, the OK status is sent to terminate
	// this RPC.
	RunClient(context.Context, *connect.BidiStream[testing.ClientArgs, testing.ClientStatus]) error
	// Just return the core count - unary call
	CoreCount(context.Context, *connect.Request[testing.CoreRequest]) (*connect.Response[testing.CoreResponse], error)
	// Quit this worker
	QuitWorker(context.Context, *connect.Request[testing.Void]) (*connect.Response[testing.Void], error)
}

WorkerServiceHandler is an implementation of the grpc.testing.WorkerService service.

type XdsUpdateClientConfigureServiceClient

type XdsUpdateClientConfigureServiceClient interface {
	// Update the tes client's configuration.
	Configure(context.Context, *connect.Request[testing.ClientConfigureRequest]) (*connect.Response[testing.ClientConfigureResponse], error)
}

XdsUpdateClientConfigureServiceClient is a client for the grpc.testing.XdsUpdateClientConfigureService service.

func NewXdsUpdateClientConfigureServiceClient

func NewXdsUpdateClientConfigureServiceClient(httpClient connect.HTTPClient, baseURL string, opts ...connect.ClientOption) XdsUpdateClientConfigureServiceClient

NewXdsUpdateClientConfigureServiceClient constructs a client for the grpc.testing.XdsUpdateClientConfigureService service. By default, it uses the Connect protocol with the binary Protobuf Codec, asks for gzipped responses, and sends uncompressed requests. To use the gRPC or gRPC-Web protocols, supply the connect.WithGRPC() or connect.WithGRPCWeb() options.

The URL supplied here should be the base URL for the Connect or gRPC server (for example, http://api.acme.com or https://acme.com/grpc).

type XdsUpdateClientConfigureServiceHandler

type XdsUpdateClientConfigureServiceHandler interface {
	// Update the tes client's configuration.
	Configure(context.Context, *connect.Request[testing.ClientConfigureRequest]) (*connect.Response[testing.ClientConfigureResponse], error)
}

XdsUpdateClientConfigureServiceHandler is an implementation of the grpc.testing.XdsUpdateClientConfigureService service.

type XdsUpdateHealthServiceClient

XdsUpdateHealthServiceClient is a client for the grpc.testing.XdsUpdateHealthService service.

func NewXdsUpdateHealthServiceClient

func NewXdsUpdateHealthServiceClient(httpClient connect.HTTPClient, baseURL string, opts ...connect.ClientOption) XdsUpdateHealthServiceClient

NewXdsUpdateHealthServiceClient constructs a client for the grpc.testing.XdsUpdateHealthService service. By default, it uses the Connect protocol with the binary Protobuf Codec, asks for gzipped responses, and sends uncompressed requests. To use the gRPC or gRPC-Web protocols, supply the connect.WithGRPC() or connect.WithGRPCWeb() options.

The URL supplied here should be the base URL for the Connect or gRPC server (for example, http://api.acme.com or https://acme.com/grpc).

type XdsUpdateHealthServiceHandler

XdsUpdateHealthServiceHandler is an implementation of the grpc.testing.XdsUpdateHealthService service.

Jump to

Keyboard shortcuts

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