grpccompat
packagemoduleThis package is not in the latest version of its module.
Details
Validgo.mod file
The Go module system was introduced in Go 1.11 and is the official dependency management solution for Go.
Redistributable license
Redistributable licenses place minimal restrictions on how software can be used, modified, and redistributed.
Tagged version
Modules with tagged versions give importers more predictable builds.
Stable version
When a project reaches major version v1 it is considered stable.
- Learn more about best practices
Repository
Links
README¶
package grpccompat
import "storj.io/drpc/internal/grpccompat"
package grpccompat holds compatability tests for grpc.
Documentation¶
Overview¶
Package grpccompat holds compatibility tests for grpc.
Index¶
- Variables
- func DRPCRegisterService(mux drpc.Mux, impl DRPCServiceServer) error
- func RegisterServiceServer(s grpc.ServiceRegistrar, srv ServiceServer)
- type DRPCServiceClient
- type DRPCServiceDescription
- type DRPCServiceServer
- type DRPCServiceUnimplementedServer
- func (s *DRPCServiceUnimplementedServer) Method1(context.Context, *In) (*Out, error)
- func (s *DRPCServiceUnimplementedServer) Method2(DRPCService_Method2Stream) error
- func (s *DRPCServiceUnimplementedServer) Method3(*In, DRPCService_Method3Stream) error
- func (s *DRPCServiceUnimplementedServer) Method4(DRPCService_Method4Stream) error
- type DRPCService_Method1Stream
- type DRPCService_Method2Client
- type DRPCService_Method2Stream
- type DRPCService_Method3Client
- type DRPCService_Method3Stream
- type DRPCService_Method4Client
- type DRPCService_Method4Stream
- type In
- type Out
- type ServiceClient
- type ServiceServer
- type Service_Method2Client
- type Service_Method2Server
- type Service_Method3Client
- type Service_Method3Server
- type Service_Method4Client
- type Service_Method4Server
- type UnimplementedServiceServer
- type UnsafeServiceServer
Constants¶
This section is empty.
Variables¶
var File_service_protoprotoreflect.FileDescriptorvar Service_ServiceDesc =grpc.ServiceDesc{ServiceName: "service.Service",HandlerType: (*ServiceServer)(nil),Methods: []grpc.MethodDesc{{MethodName: "Method1",Handler: _Service_Method1_Handler,},},Streams: []grpc.StreamDesc{{StreamName: "Method2",Handler: _Service_Method2_Handler,ClientStreams:true,},{StreamName: "Method3",Handler: _Service_Method3_Handler,ServerStreams:true,},{StreamName: "Method4",Handler: _Service_Method4_Handler,ServerStreams:true,ClientStreams:true,},},Metadata: "service.proto",}
Service_ServiceDesc is the grpc.ServiceDesc for Service service.It's only intended for direct use with grpc.RegisterService,and not to be introspected or modified (even as a copy)
Functions¶
funcDRPCRegisterService¶
func DRPCRegisterService(muxdrpc.Mux, implDRPCServiceServer)error
funcRegisterServiceServer¶
func RegisterServiceServer(sgrpc.ServiceRegistrar, srvServiceServer)
Types¶
typeDRPCServiceClient¶
type DRPCServiceClient interface {DRPCConn()drpc.ConnMethod1(ctxcontext.Context, in *In) (*Out,error)Method2(ctxcontext.Context) (DRPCService_Method2Client,error)Method3(ctxcontext.Context, in *In) (DRPCService_Method3Client,error)Method4(ctxcontext.Context) (DRPCService_Method4Client,error)}funcNewDRPCServiceClient¶
func NewDRPCServiceClient(ccdrpc.Conn)DRPCServiceClient
typeDRPCServiceDescription¶
type DRPCServiceDescription struct{}func (DRPCServiceDescription)NumMethods¶
func (DRPCServiceDescription) NumMethods()int
typeDRPCServiceServer¶
type DRPCServiceServer interface {Method1(context.Context, *In) (*Out,error)Method2(DRPCService_Method2Stream)errorMethod3(*In,DRPCService_Method3Stream)errorMethod4(DRPCService_Method4Stream)error}typeDRPCServiceUnimplementedServer¶
type DRPCServiceUnimplementedServer struct{}func (*DRPCServiceUnimplementedServer)Method2¶
func (s *DRPCServiceUnimplementedServer) Method2(DRPCService_Method2Stream)error
func (*DRPCServiceUnimplementedServer)Method3¶
func (s *DRPCServiceUnimplementedServer) Method3(*In,DRPCService_Method3Stream)error
func (*DRPCServiceUnimplementedServer)Method4¶
func (s *DRPCServiceUnimplementedServer) Method4(DRPCService_Method4Stream)error
typeIn¶
type In struct {Inint64 `protobuf:"varint,1,opt,name=in,proto3" json:"in,omitempty"`Buf []byte `protobuf:"bytes,2,opt,name=buf,proto3" json:"buf,omitempty"`Opt *int64 `protobuf:"varint,3,opt,name=opt,proto3,oneof" json:"opt,omitempty"`// contains filtered or unexported fields} func (*In)Descriptordeprecated
func (*In)ProtoMessage¶
func (*In) ProtoMessage()
func (*In)ProtoReflect¶
func (x *In) ProtoReflect()protoreflect.Message
typeOut¶
type Out struct {Outint64 `protobuf:"varint,1,opt,name=out,proto3" json:"out,omitempty"`Buf []byte `protobuf:"bytes,2,opt,name=buf,proto3" json:"buf,omitempty"`Opt *int64 `protobuf:"varint,3,opt,name=opt,proto3,oneof" json:"opt,omitempty"`// contains filtered or unexported fields} func (*Out)Descriptordeprecated
func (*Out)ProtoMessage¶
func (*Out) ProtoMessage()
func (*Out)ProtoReflect¶
func (x *Out) ProtoReflect()protoreflect.Message
typeServiceClient¶
type ServiceClient interface {Method1(ctxcontext.Context, in *In, opts ...grpc.CallOption) (*Out,error)Method2(ctxcontext.Context, opts ...grpc.CallOption) (Service_Method2Client,error)Method3(ctxcontext.Context, in *In, opts ...grpc.CallOption) (Service_Method3Client,error)Method4(ctxcontext.Context, opts ...grpc.CallOption) (Service_Method4Client,error)}ServiceClient is the client API for Service service.
For semantics around ctx use and closing/ending streaming RPCs, please refer tohttps://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
funcNewServiceClient¶
func NewServiceClient(ccgrpc.ClientConnInterface)ServiceClient
typeServiceServer¶
type ServiceServer interface {Method1(context.Context, *In) (*Out,error)Method2(Service_Method2Server)errorMethod3(*In,Service_Method3Server)errorMethod4(Service_Method4Server)error// contains filtered or unexported methods}ServiceServer is the server API for Service service.All implementations must embed UnimplementedServiceServerfor forward compatibility
typeService_Method3Client¶
type Service_Method3Client interface {Recv() (*Out,error)grpc.ClientStream}typeService_Method3Server¶
type Service_Method3Server interface {Send(*Out)errorgrpc.ServerStream}typeUnimplementedServiceServer¶
type UnimplementedServiceServer struct {}UnimplementedServiceServer must be embedded to have forward compatible implementations.
func (UnimplementedServiceServer)Method2¶
func (UnimplementedServiceServer) Method2(Service_Method2Server)error
func (UnimplementedServiceServer)Method3¶
func (UnimplementedServiceServer) Method3(*In,Service_Method3Server)error
func (UnimplementedServiceServer)Method4¶
func (UnimplementedServiceServer) Method4(Service_Method4Server)error
typeUnsafeServiceServer¶
type UnsafeServiceServer interface {// contains filtered or unexported methods}UnsafeServiceServer may be embedded to opt out of forward compatibility for this service.Use of this interface is not recommended, as added methods to ServiceServer willresult in compilation errors.