Documentation
¶
Index ¶
- Variables
- type Service
- func (s *Service) AddItem(_ context.Context, request *pb.AddItemPrivateRequest) (*pb.AddItemPrivateResponse, error)
- func (s *Service) GetItemById(_ context.Context, request *pb.GetItemByIdPrivateRequest) (*pb.GetItemByIdPrivateResponse, error)
- func (s *Service) GetKnapsack(_ context.Context, request *pb.GetKnapsackRequest) (*pb.GetKnapsackResponse, error)
- func (s *Service) RegisterWithGrpcServer(server siface.IGrpcServer) error
- func (s *Service) RemoveItem(_ context.Context, request *pb.RemoveItemPrivateRequest) (*pb.RemoveItemPrivateResponse, error)
Constants ¶
This section is empty.
Variables ¶
View Source
var Module = fx.Provide( func( logger *zap.Logger, dbProvider ofx.DocumentStoreParams, setting kfx.KnapsackSettingParams, mParams mfx.MessageQueueParams, rcParams ofx.RedisCacheParams, ) (out sfx.GrpcServiceResult, err error) { if coll, e := dbProvider.DriverProvider.OpenDbDriver(setting.KnapsackStoreName); e != nil { err = e } else { if svc, e := NewService( logger, coll, mParams.MessageQueue, rcParams.RedisCache, ); e != nil { err = e } else { out.GrpcService = svc } } return }, )
Functions ¶
This section is empty.
Types ¶
type Service ¶
type Service struct { utility.WithoutAuth // contains filtered or unexported fields }
func NewService ¶
func NewService( l *zap.Logger, coll diface.ICollection, mq miface.MessageQueue, redisCache diface.ICache, ) (result *Service, err error)
func (*Service) AddItem ¶
func (s *Service) AddItem(_ context.Context, request *pb.AddItemPrivateRequest) (*pb.AddItemPrivateResponse, error)
func (*Service) GetItemById ¶
func (s *Service) GetItemById(_ context.Context, request *pb.GetItemByIdPrivateRequest) (*pb.GetItemByIdPrivateResponse, error)
func (*Service) GetKnapsack ¶
func (s *Service) GetKnapsack(_ context.Context, request *pb.GetKnapsackRequest) (*pb.GetKnapsackResponse, error)
func (*Service) RegisterWithGrpcServer ¶
func (s *Service) RegisterWithGrpcServer(server siface.IGrpcServer) error
func (*Service) RemoveItem ¶
func (s *Service) RemoveItem(_ context.Context, request *pb.RemoveItemPrivateRequest) (*pb.RemoveItemPrivateResponse, error)
Click to show internal directories.
Click to hide internal directories.