Documentation
¶
Index ¶
- type Server
- func (s Server) Attach(req *pb.AttachRequest, stream pb.AWEService_AttachServer) error
- func (s Server) Chat(req *pb.ChatRequest, stream pb.AWEService_ChatServer) error
- func (s Server) Execute(req *pb.ExecuteRequest, stream pb.AWEService_ExecuteServer) error
- func (s Server) Search(req *pb.SearchRequest, stream pb.AWEService_SearchServer) error
- func (s Server) Serve() error
- func (s Server) Trace(ctx context.Context, req *pb.TraceRequest) (*pb.TraceResponse, error)
- type ServerConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Server ¶
type Server struct {
pb.UnimplementedAWEServiceServer
// contains filtered or unexported fields
}
Server implements the AWEService
func New ¶
func New(config ServerConfig) *Server
func (Server) Attach ¶
func (s Server) Attach(req *pb.AttachRequest, stream pb.AWEService_AttachServer) error
func (Server) Chat ¶
func (s Server) Chat(req *pb.ChatRequest, stream pb.AWEService_ChatServer) error
func (Server) Execute ¶
func (s Server) Execute(req *pb.ExecuteRequest, stream pb.AWEService_ExecuteServer) error
func (Server) Search ¶
func (s Server) Search(req *pb.SearchRequest, stream pb.AWEService_SearchServer) error
func (Server) Trace ¶
func (s Server) Trace(ctx context.Context, req *pb.TraceRequest) (*pb.TraceResponse, error)
type ServerConfig ¶
type ServerConfig struct {
ListenHost string
ListenPort int
RedisAddr string
RedisUsername string
RedisPassword string
RedisDB int
}
func DefaultConfig ¶
func DefaultConfig() ServerConfig
Click to show internal directories.
Click to hide internal directories.