Documentation ¶
Index ¶
- Constants
- Variables
- func RegisterGroupCacheTestServer(s grpc.ServiceRegistrar, srv GroupCacheTestServer)
- type CacheStats
- func (*CacheStats) Descriptor() ([]byte, []int)deprecated
- func (x *CacheStats) GetBytes() int64
- func (x *CacheStats) GetEvicts() int64
- func (x *CacheStats) GetGets() int64
- func (x *CacheStats) GetHits() int64
- func (x *CacheStats) GetItems() int64
- func (*CacheStats) ProtoMessage()
- func (x *CacheStats) ProtoReflect() protoreflect.Message
- func (x *CacheStats) Reset()
- func (x *CacheStats) String() string
- type Empty
- type GroupCacheTestClient
- type GroupCacheTestServer
- type StatsResponse
- func (*StatsResponse) Descriptor() ([]byte, []int)deprecated
- func (x *StatsResponse) GetCacheHits() int64
- func (x *StatsResponse) GetFills() int64
- func (x *StatsResponse) GetGets() int64
- func (x *StatsResponse) GetHotCache() *CacheStats
- func (x *StatsResponse) GetLoads() int64
- func (x *StatsResponse) GetLocalLoads() int64
- func (x *StatsResponse) GetMainCache() *CacheStats
- func (x *StatsResponse) GetPeerErrors() int64
- func (x *StatsResponse) GetPeerLoads() int64
- func (x *StatsResponse) GetServerIn() int64
- func (x *StatsResponse) GetTotalAlloc() uint64
- func (*StatsResponse) ProtoMessage()
- func (x *StatsResponse) ProtoReflect() protoreflect.Message
- func (x *StatsResponse) Reset()
- func (x *StatsResponse) String() string
- type TestMessage
- type TestRequest
- func (*TestRequest) Descriptor() ([]byte, []int)deprecated
- func (x *TestRequest) GetLower() string
- func (x *TestRequest) GetRepeatCount() int32
- func (*TestRequest) ProtoMessage()
- func (x *TestRequest) ProtoReflect() protoreflect.Message
- func (x *TestRequest) Reset()
- func (x *TestRequest) String() string
- type TestResponse
- type UnimplementedGroupCacheTestServer
- type UnsafeGroupCacheTestServer
Constants ¶
const ( GroupCacheTest_InitPeers_FullMethodName = "/testpb.GroupCacheTest/InitPeers" GroupCacheTest_Get_FullMethodName = "/testpb.GroupCacheTest/Get" GroupCacheTest_GetStats_FullMethodName = "/testpb.GroupCacheTest/GetStats" )
Variables ¶
var File_testpb_test_proto protoreflect.FileDescriptor
var GroupCacheTest_ServiceDesc = grpc.ServiceDesc{ ServiceName: "testpb.GroupCacheTest", HandlerType: (*GroupCacheTestServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "InitPeers", Handler: _GroupCacheTest_InitPeers_Handler, }, { MethodName: "Get", Handler: _GroupCacheTest_Get_Handler, }, { MethodName: "GetStats", Handler: _GroupCacheTest_GetStats_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "testpb/test.proto", }
GroupCacheTest_ServiceDesc is the grpc.ServiceDesc for GroupCacheTest service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterGroupCacheTestServer ¶
func RegisterGroupCacheTestServer(s grpc.ServiceRegistrar, srv GroupCacheTestServer)
Types ¶
type CacheStats ¶
type CacheStats struct { Items int64 `protobuf:"varint,1,opt,name=items,proto3" json:"items,omitempty"` Bytes int64 `protobuf:"varint,2,opt,name=bytes,proto3" json:"bytes,omitempty"` Gets int64 `protobuf:"varint,3,opt,name=gets,proto3" json:"gets,omitempty"` Hits int64 `protobuf:"varint,4,opt,name=hits,proto3" json:"hits,omitempty"` Evicts int64 `protobuf:"varint,5,opt,name=evicts,proto3" json:"evicts,omitempty"` // contains filtered or unexported fields }
func (*CacheStats) Descriptor
deprecated
func (*CacheStats) Descriptor() ([]byte, []int)
Deprecated: Use CacheStats.ProtoReflect.Descriptor instead.
func (*CacheStats) GetBytes ¶
func (x *CacheStats) GetBytes() int64
func (*CacheStats) GetEvicts ¶
func (x *CacheStats) GetEvicts() int64
func (*CacheStats) GetGets ¶
func (x *CacheStats) GetGets() int64
func (*CacheStats) GetHits ¶
func (x *CacheStats) GetHits() int64
func (*CacheStats) GetItems ¶
func (x *CacheStats) GetItems() int64
func (*CacheStats) ProtoMessage ¶
func (*CacheStats) ProtoMessage()
func (*CacheStats) ProtoReflect ¶
func (x *CacheStats) ProtoReflect() protoreflect.Message
func (*CacheStats) Reset ¶
func (x *CacheStats) Reset()
func (*CacheStats) String ¶
func (x *CacheStats) String() string
type Empty ¶
type Empty struct {
// contains filtered or unexported fields
}
func (*Empty) Descriptor
deprecated
func (*Empty) ProtoMessage ¶
func (*Empty) ProtoMessage()
func (*Empty) ProtoReflect ¶
func (x *Empty) ProtoReflect() protoreflect.Message
type GroupCacheTestClient ¶
type GroupCacheTestClient interface { InitPeers(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*Empty, error) Get(ctx context.Context, in *TestRequest, opts ...grpc.CallOption) (*TestResponse, error) GetStats(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*StatsResponse, error) }
GroupCacheTestClient is the client API for GroupCacheTest 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 NewGroupCacheTestClient ¶
func NewGroupCacheTestClient(cc grpc.ClientConnInterface) GroupCacheTestClient
type GroupCacheTestServer ¶
type GroupCacheTestServer interface { InitPeers(context.Context, *Empty) (*Empty, error) Get(context.Context, *TestRequest) (*TestResponse, error) GetStats(context.Context, *Empty) (*StatsResponse, error) // contains filtered or unexported methods }
GroupCacheTestServer is the server API for GroupCacheTest service. All implementations must embed UnimplementedGroupCacheTestServer for forward compatibility
type StatsResponse ¶
type StatsResponse struct { Gets int64 `protobuf:"varint,1,opt,name=gets,proto3" json:"gets,omitempty"` CacheHits int64 `protobuf:"varint,12,opt,name=cache_hits,json=cacheHits,proto3" json:"cache_hits,omitempty"` Fills int64 `protobuf:"varint,2,opt,name=fills,proto3" json:"fills,omitempty"` TotalAlloc uint64 `protobuf:"varint,3,opt,name=total_alloc,json=totalAlloc,proto3" json:"total_alloc,omitempty"` MainCache *CacheStats `protobuf:"bytes,4,opt,name=main_cache,json=mainCache,proto3" json:"main_cache,omitempty"` HotCache *CacheStats `protobuf:"bytes,5,opt,name=hot_cache,json=hotCache,proto3" json:"hot_cache,omitempty"` ServerIn int64 `protobuf:"varint,6,opt,name=server_in,json=serverIn,proto3" json:"server_in,omitempty"` Loads int64 `protobuf:"varint,8,opt,name=loads,proto3" json:"loads,omitempty"` PeerLoads int64 `protobuf:"varint,9,opt,name=peer_loads,json=peerLoads,proto3" json:"peer_loads,omitempty"` PeerErrors int64 `protobuf:"varint,10,opt,name=peer_errors,json=peerErrors,proto3" json:"peer_errors,omitempty"` LocalLoads int64 `protobuf:"varint,11,opt,name=local_loads,json=localLoads,proto3" json:"local_loads,omitempty"` // contains filtered or unexported fields }
func (*StatsResponse) Descriptor
deprecated
func (*StatsResponse) Descriptor() ([]byte, []int)
Deprecated: Use StatsResponse.ProtoReflect.Descriptor instead.
func (*StatsResponse) GetCacheHits ¶
func (x *StatsResponse) GetCacheHits() int64
func (*StatsResponse) GetFills ¶
func (x *StatsResponse) GetFills() int64
func (*StatsResponse) GetGets ¶
func (x *StatsResponse) GetGets() int64
func (*StatsResponse) GetHotCache ¶
func (x *StatsResponse) GetHotCache() *CacheStats
func (*StatsResponse) GetLoads ¶
func (x *StatsResponse) GetLoads() int64
func (*StatsResponse) GetLocalLoads ¶
func (x *StatsResponse) GetLocalLoads() int64
func (*StatsResponse) GetMainCache ¶
func (x *StatsResponse) GetMainCache() *CacheStats
func (*StatsResponse) GetPeerErrors ¶
func (x *StatsResponse) GetPeerErrors() int64
func (*StatsResponse) GetPeerLoads ¶
func (x *StatsResponse) GetPeerLoads() int64
func (*StatsResponse) GetServerIn ¶
func (x *StatsResponse) GetServerIn() int64
func (*StatsResponse) GetTotalAlloc ¶
func (x *StatsResponse) GetTotalAlloc() uint64
func (*StatsResponse) ProtoMessage ¶
func (*StatsResponse) ProtoMessage()
func (*StatsResponse) ProtoReflect ¶
func (x *StatsResponse) ProtoReflect() protoreflect.Message
func (*StatsResponse) Reset ¶
func (x *StatsResponse) Reset()
func (*StatsResponse) String ¶
func (x *StatsResponse) String() string
type TestMessage ¶
type TestMessage struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` City string `protobuf:"bytes,2,opt,name=city,proto3" json:"city,omitempty"` // contains filtered or unexported fields }
func (*TestMessage) Descriptor
deprecated
func (*TestMessage) Descriptor() ([]byte, []int)
Deprecated: Use TestMessage.ProtoReflect.Descriptor instead.
func (*TestMessage) GetCity ¶
func (x *TestMessage) GetCity() string
func (*TestMessage) GetName ¶
func (x *TestMessage) GetName() string
func (*TestMessage) ProtoMessage ¶
func (*TestMessage) ProtoMessage()
func (*TestMessage) ProtoReflect ¶
func (x *TestMessage) ProtoReflect() protoreflect.Message
func (*TestMessage) Reset ¶
func (x *TestMessage) Reset()
func (*TestMessage) String ¶
func (x *TestMessage) String() string
type TestRequest ¶
type TestRequest struct { Lower string `protobuf:"bytes,1,opt,name=lower,proto3" json:"lower,omitempty"` // to be returned upper case RepeatCount int32 `protobuf:"varint,2,opt,name=repeat_count,json=repeatCount,proto3" json:"repeat_count,omitempty"` // .. this many times // contains filtered or unexported fields }
func (*TestRequest) Descriptor
deprecated
func (*TestRequest) Descriptor() ([]byte, []int)
Deprecated: Use TestRequest.ProtoReflect.Descriptor instead.
func (*TestRequest) GetLower ¶
func (x *TestRequest) GetLower() string
func (*TestRequest) GetRepeatCount ¶
func (x *TestRequest) GetRepeatCount() int32
func (*TestRequest) ProtoMessage ¶
func (*TestRequest) ProtoMessage()
func (*TestRequest) ProtoReflect ¶
func (x *TestRequest) ProtoReflect() protoreflect.Message
func (*TestRequest) Reset ¶
func (x *TestRequest) Reset()
func (*TestRequest) String ¶
func (x *TestRequest) String() string
type TestResponse ¶
type TestResponse struct { Value string `protobuf:"bytes,1,opt,name=value,proto3" json:"value,omitempty"` // contains filtered or unexported fields }
func (*TestResponse) Descriptor
deprecated
func (*TestResponse) Descriptor() ([]byte, []int)
Deprecated: Use TestResponse.ProtoReflect.Descriptor instead.
func (*TestResponse) GetValue ¶
func (x *TestResponse) GetValue() string
func (*TestResponse) ProtoMessage ¶
func (*TestResponse) ProtoMessage()
func (*TestResponse) ProtoReflect ¶
func (x *TestResponse) ProtoReflect() protoreflect.Message
func (*TestResponse) Reset ¶
func (x *TestResponse) Reset()
func (*TestResponse) String ¶
func (x *TestResponse) String() string
type UnimplementedGroupCacheTestServer ¶
type UnimplementedGroupCacheTestServer struct { }
UnimplementedGroupCacheTestServer must be embedded to have forward compatible implementations.
func (UnimplementedGroupCacheTestServer) Get ¶
func (UnimplementedGroupCacheTestServer) Get(context.Context, *TestRequest) (*TestResponse, error)
func (UnimplementedGroupCacheTestServer) GetStats ¶
func (UnimplementedGroupCacheTestServer) GetStats(context.Context, *Empty) (*StatsResponse, error)
type UnsafeGroupCacheTestServer ¶
type UnsafeGroupCacheTestServer interface {
// contains filtered or unexported methods
}
UnsafeGroupCacheTestServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to GroupCacheTestServer will result in compilation errors.