Documentation ¶
Overview ¶
Package _proto is a generated protocol buffer package.
It is generated from these files:
_proto/lookaside.proto
It has these top-level messages:
Request Response
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var Request_RouterType_name = map[int32]string{
0: "RANDOM",
1: "ROUNDROBIN",
2: "HASH",
}
View Source
var Request_RouterType_value = map[string]int32{
"RANDOM": 0,
"ROUNDROBIN": 1,
"HASH": 2,
}
Functions ¶
func RegisterLookasideServer ¶
func RegisterLookasideServer(s *grpc.Server, srv LookasideServer)
Types ¶
type LookasideClient ¶
type LookasideClient interface {
Resolve(ctx context.Context, in *Request, opts ...grpc.CallOption) (*Response, error)
}
func NewLookasideClient ¶
func NewLookasideClient(cc *grpc.ClientConn) LookasideClient
type LookasideServer ¶
type Request ¶
type Request struct { Router Request_RouterType `protobuf:"varint,1,opt,name=router,enum=_proto.Request_RouterType" json:"router,omitempty"` Service string `protobuf:"bytes,2,opt,name=service" json:"service,omitempty"` Hash []byte `protobuf:"bytes,3,opt,name=hash,proto3" json:"hash,omitempty"` }
func (*Request) Descriptor ¶
func (*Request) GetRouter ¶
func (m *Request) GetRouter() Request_RouterType
func (*Request) GetService ¶
func (*Request) ProtoMessage ¶
func (*Request) ProtoMessage()
type Request_RouterType ¶
type Request_RouterType int32
const ( Request_RANDOM Request_RouterType = 0 Request_ROUNDROBIN Request_RouterType = 1 Request_HASH Request_RouterType = 2 )
func (Request_RouterType) EnumDescriptor ¶
func (Request_RouterType) EnumDescriptor() ([]byte, []int)
func (Request_RouterType) String ¶
func (x Request_RouterType) String() string
type Response ¶
type Response struct {
Address string `protobuf:"bytes,1,opt,name=address" json:"address,omitempty"`
}
func (*Response) Descriptor ¶
func (*Response) GetAddress ¶
func (*Response) ProtoMessage ¶
func (*Response) ProtoMessage()
Click to show internal directories.
Click to hide internal directories.