Documentation
¶
Index ¶
- Variables
- func RegisterIndexServer(s *grpc.Server, srv IndexServer)
- type Document
- func (*Document) Descriptor() ([]byte, []int)
- func (m *Document) GetFields() *any.Any
- func (m *Document) GetId() string
- func (*Document) ProtoMessage()
- func (m *Document) Reset()
- func (m *Document) String() string
- func (m *Document) XXX_DiscardUnknown()
- func (m *Document) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Document) XXX_Merge(src proto.Message)
- func (m *Document) XXX_Size() int
- func (m *Document) XXX_Unmarshal(b []byte) error
- type IndexClient
- type IndexCommand
- func (*IndexCommand) Descriptor() ([]byte, []int)
- func (m *IndexCommand) GetData() *any.Any
- func (m *IndexCommand) GetType() IndexCommand_Type
- func (*IndexCommand) ProtoMessage()
- func (m *IndexCommand) Reset()
- func (m *IndexCommand) String() string
- func (m *IndexCommand) XXX_DiscardUnknown()
- func (m *IndexCommand) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *IndexCommand) XXX_Merge(src proto.Message)
- func (m *IndexCommand) XXX_Size() int
- func (m *IndexCommand) XXX_Unmarshal(b []byte) error
- type IndexCommand_Type
- type IndexServer
- type Index_DeleteClient
- type Index_DeleteServer
- type Index_IndexClient
- type Index_IndexServer
- type SearchRequest
- func (*SearchRequest) Descriptor() ([]byte, []int)
- func (m *SearchRequest) GetSearchRequest() *any.Any
- func (*SearchRequest) ProtoMessage()
- func (m *SearchRequest) Reset()
- func (m *SearchRequest) String() string
- func (m *SearchRequest) XXX_DiscardUnknown()
- func (m *SearchRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *SearchRequest) XXX_Merge(src proto.Message)
- func (m *SearchRequest) XXX_Size() int
- func (m *SearchRequest) XXX_Unmarshal(b []byte) error
- type SearchResponse
- func (*SearchResponse) Descriptor() ([]byte, []int)
- func (m *SearchResponse) GetSearchResult() *any.Any
- func (*SearchResponse) ProtoMessage()
- func (m *SearchResponse) Reset()
- func (m *SearchResponse) String() string
- func (m *SearchResponse) XXX_DiscardUnknown()
- func (m *SearchResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *SearchResponse) XXX_Merge(src proto.Message)
- func (m *SearchResponse) XXX_Size() int
- func (m *SearchResponse) XXX_Unmarshal(b []byte) error
- type Stats
- func (*Stats) Descriptor() ([]byte, []int)
- func (m *Stats) GetStats() *any.Any
- func (*Stats) ProtoMessage()
- func (m *Stats) Reset()
- func (m *Stats) String() string
- func (m *Stats) XXX_DiscardUnknown()
- func (m *Stats) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *Stats) XXX_Merge(src proto.Message)
- func (m *Stats) XXX_Size() int
- func (m *Stats) XXX_Unmarshal(b []byte) error
- type UpdateResult
- func (*UpdateResult) Descriptor() ([]byte, []int)
- func (m *UpdateResult) GetCount() int32
- func (*UpdateResult) ProtoMessage()
- func (m *UpdateResult) Reset()
- func (m *UpdateResult) String() string
- func (m *UpdateResult) XXX_DiscardUnknown()
- func (m *UpdateResult) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *UpdateResult) XXX_Merge(src proto.Message)
- func (m *UpdateResult) XXX_Size() int
- func (m *UpdateResult) XXX_Unmarshal(b []byte) error
Constants ¶
This section is empty.
Variables ¶
View Source
var IndexCommand_Type_name = map[int32]string{
0: "UNKNOWN_COMMAND",
1: "SET_METADATA",
2: "DELETE_METADATA",
3: "INDEX_DOCUMENT",
4: "DELETE_DOCUMENT",
}
View Source
var IndexCommand_Type_value = map[string]int32{
"UNKNOWN_COMMAND": 0,
"SET_METADATA": 1,
"DELETE_METADATA": 2,
"INDEX_DOCUMENT": 3,
"DELETE_DOCUMENT": 4,
}
Functions ¶
func RegisterIndexServer ¶
func RegisterIndexServer(s *grpc.Server, srv IndexServer)
Types ¶
type Document ¶
type Document struct {
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
Fields *any.Any `protobuf:"bytes,2,opt,name=fields,proto3" json:"fields,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (*Document) Descriptor ¶
func (*Document) ProtoMessage ¶
func (*Document) ProtoMessage()
func (*Document) XXX_DiscardUnknown ¶
func (m *Document) XXX_DiscardUnknown()
func (*Document) XXX_Marshal ¶
func (*Document) XXX_Unmarshal ¶
type IndexClient ¶
type IndexClient interface {
Join(ctx context.Context, in *raft.Node, opts ...grpc.CallOption) (*empty.Empty, error)
Leave(ctx context.Context, in *raft.Node, opts ...grpc.CallOption) (*empty.Empty, error)
GetNode(ctx context.Context, in *empty.Empty, opts ...grpc.CallOption) (*raft.Node, error)
GetCluster(ctx context.Context, in *empty.Empty, opts ...grpc.CallOption) (*raft.Cluster, error)
Snapshot(ctx context.Context, in *empty.Empty, opts ...grpc.CallOption) (*empty.Empty, error)
Get(ctx context.Context, in *Document, opts ...grpc.CallOption) (*Document, error)
Index(ctx context.Context, opts ...grpc.CallOption) (Index_IndexClient, error)
Delete(ctx context.Context, opts ...grpc.CallOption) (Index_DeleteClient, error)
Search(ctx context.Context, in *SearchRequest, opts ...grpc.CallOption) (*SearchResponse, error)
GetStats(ctx context.Context, in *empty.Empty, opts ...grpc.CallOption) (*Stats, error)
}
IndexClient is the client API for Index service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewIndexClient ¶
func NewIndexClient(cc *grpc.ClientConn) IndexClient
type IndexCommand ¶
type IndexCommand struct {
Type IndexCommand_Type `protobuf:"varint,1,opt,name=type,proto3,enum=index.IndexCommand_Type" json:"type,omitempty"`
Data *any.Any `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (*IndexCommand) Descriptor ¶
func (*IndexCommand) Descriptor() ([]byte, []int)
func (*IndexCommand) GetData ¶
func (m *IndexCommand) GetData() *any.Any
func (*IndexCommand) GetType ¶
func (m *IndexCommand) GetType() IndexCommand_Type
func (*IndexCommand) ProtoMessage ¶
func (*IndexCommand) ProtoMessage()
func (*IndexCommand) Reset ¶
func (m *IndexCommand) Reset()
func (*IndexCommand) String ¶
func (m *IndexCommand) String() string
func (*IndexCommand) XXX_DiscardUnknown ¶
func (m *IndexCommand) XXX_DiscardUnknown()
func (*IndexCommand) XXX_Marshal ¶
func (m *IndexCommand) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*IndexCommand) XXX_Merge ¶
func (m *IndexCommand) XXX_Merge(src proto.Message)
func (*IndexCommand) XXX_Size ¶
func (m *IndexCommand) XXX_Size() int
func (*IndexCommand) XXX_Unmarshal ¶
func (m *IndexCommand) XXX_Unmarshal(b []byte) error
type IndexCommand_Type ¶
type IndexCommand_Type int32
const ( IndexCommand_UNKNOWN_COMMAND IndexCommand_Type = 0 IndexCommand_SET_METADATA IndexCommand_Type = 1 IndexCommand_DELETE_METADATA IndexCommand_Type = 2 IndexCommand_INDEX_DOCUMENT IndexCommand_Type = 3 IndexCommand_DELETE_DOCUMENT IndexCommand_Type = 4 )
func (IndexCommand_Type) EnumDescriptor ¶
func (IndexCommand_Type) EnumDescriptor() ([]byte, []int)
func (IndexCommand_Type) String ¶
func (x IndexCommand_Type) String() string
type IndexServer ¶
type IndexServer interface {
Join(context.Context, *raft.Node) (*empty.Empty, error)
Leave(context.Context, *raft.Node) (*empty.Empty, error)
GetNode(context.Context, *empty.Empty) (*raft.Node, error)
GetCluster(context.Context, *empty.Empty) (*raft.Cluster, error)
Snapshot(context.Context, *empty.Empty) (*empty.Empty, error)
Get(context.Context, *Document) (*Document, error)
Index(Index_IndexServer) error
Delete(Index_DeleteServer) error
Search(context.Context, *SearchRequest) (*SearchResponse, error)
GetStats(context.Context, *empty.Empty) (*Stats, error)
}
IndexServer is the server API for Index service.
type Index_DeleteClient ¶ added in v0.5.0
type Index_DeleteClient interface {
Send(*Document) error
CloseAndRecv() (*UpdateResult, error)
grpc.ClientStream
}
type Index_DeleteServer ¶ added in v0.5.0
type Index_DeleteServer interface {
SendAndClose(*UpdateResult) error
Recv() (*Document, error)
grpc.ServerStream
}
type Index_IndexClient ¶ added in v0.5.0
type Index_IndexClient interface {
Send(*Document) error
CloseAndRecv() (*UpdateResult, error)
grpc.ClientStream
}
type Index_IndexServer ¶ added in v0.5.0
type Index_IndexServer interface {
SendAndClose(*UpdateResult) error
Recv() (*Document, error)
grpc.ServerStream
}
type SearchRequest ¶
type SearchRequest struct {
SearchRequest *any.Any `protobuf:"bytes,1,opt,name=search_request,json=searchRequest,proto3" json:"search_request,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (*SearchRequest) Descriptor ¶
func (*SearchRequest) Descriptor() ([]byte, []int)
func (*SearchRequest) GetSearchRequest ¶
func (m *SearchRequest) GetSearchRequest() *any.Any
func (*SearchRequest) ProtoMessage ¶
func (*SearchRequest) ProtoMessage()
func (*SearchRequest) Reset ¶
func (m *SearchRequest) Reset()
func (*SearchRequest) String ¶
func (m *SearchRequest) String() string
func (*SearchRequest) XXX_DiscardUnknown ¶
func (m *SearchRequest) XXX_DiscardUnknown()
func (*SearchRequest) XXX_Marshal ¶
func (m *SearchRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*SearchRequest) XXX_Merge ¶
func (m *SearchRequest) XXX_Merge(src proto.Message)
func (*SearchRequest) XXX_Size ¶
func (m *SearchRequest) XXX_Size() int
func (*SearchRequest) XXX_Unmarshal ¶
func (m *SearchRequest) XXX_Unmarshal(b []byte) error
type SearchResponse ¶
type SearchResponse struct {
SearchResult *any.Any `protobuf:"bytes,1,opt,name=search_result,json=searchResult,proto3" json:"search_result,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (*SearchResponse) Descriptor ¶
func (*SearchResponse) Descriptor() ([]byte, []int)
func (*SearchResponse) GetSearchResult ¶
func (m *SearchResponse) GetSearchResult() *any.Any
func (*SearchResponse) ProtoMessage ¶
func (*SearchResponse) ProtoMessage()
func (*SearchResponse) Reset ¶
func (m *SearchResponse) Reset()
func (*SearchResponse) String ¶
func (m *SearchResponse) String() string
func (*SearchResponse) XXX_DiscardUnknown ¶
func (m *SearchResponse) XXX_DiscardUnknown()
func (*SearchResponse) XXX_Marshal ¶
func (m *SearchResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*SearchResponse) XXX_Merge ¶
func (m *SearchResponse) XXX_Merge(src proto.Message)
func (*SearchResponse) XXX_Size ¶
func (m *SearchResponse) XXX_Size() int
func (*SearchResponse) XXX_Unmarshal ¶
func (m *SearchResponse) XXX_Unmarshal(b []byte) error
type Stats ¶ added in v0.5.0
type Stats struct {
Stats *any.Any `protobuf:"bytes,1,opt,name=stats,proto3" json:"stats,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (*Stats) Descriptor ¶ added in v0.5.0
func (*Stats) ProtoMessage ¶ added in v0.5.0
func (*Stats) ProtoMessage()
func (*Stats) XXX_DiscardUnknown ¶ added in v0.5.0
func (m *Stats) XXX_DiscardUnknown()
func (*Stats) XXX_Marshal ¶ added in v0.5.0
func (*Stats) XXX_Unmarshal ¶ added in v0.5.0
type UpdateResult ¶ added in v0.5.0
type UpdateResult struct {
Count int32 `protobuf:"varint,1,opt,name=count,proto3" json:"count,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (*UpdateResult) Descriptor ¶ added in v0.5.0
func (*UpdateResult) Descriptor() ([]byte, []int)
func (*UpdateResult) GetCount ¶ added in v0.5.0
func (m *UpdateResult) GetCount() int32
func (*UpdateResult) ProtoMessage ¶ added in v0.5.0
func (*UpdateResult) ProtoMessage()
func (*UpdateResult) Reset ¶ added in v0.5.0
func (m *UpdateResult) Reset()
func (*UpdateResult) String ¶ added in v0.5.0
func (m *UpdateResult) String() string
func (*UpdateResult) XXX_DiscardUnknown ¶ added in v0.5.0
func (m *UpdateResult) XXX_DiscardUnknown()
func (*UpdateResult) XXX_Marshal ¶ added in v0.5.0
func (m *UpdateResult) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*UpdateResult) XXX_Merge ¶ added in v0.5.0
func (m *UpdateResult) XXX_Merge(src proto.Message)
func (*UpdateResult) XXX_Size ¶ added in v0.5.0
func (m *UpdateResult) XXX_Size() int
func (*UpdateResult) XXX_Unmarshal ¶ added in v0.5.0
func (m *UpdateResult) XXX_Unmarshal(b []byte) error
Click to show internal directories.
Click to hide internal directories.