public

package
v0.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 14, 2025 License: MIT Imports: 21 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ServiceModule = fx.Provide(
	func(
		l *zap.Logger,
		s mfx2.AppParams,
		ms mailfx.MailSettingParams,
		mqParams mfx.MessageQueueParams,
		redisParams ofx.RedisParams,
		aParams mfx2.AppParams,
	) (out sfx.GrpcServiceResult, err error) {
		if svc, e := NewService(
			l,
			s.Deployment,
			redisParams.Redis,
			ms.MailUrl,
			ms.MailNumMax,
			mqParams.MessageQueue,
			aParams,
		); e != nil {
			err = e
			return
		} else {
			out.GrpcService = svc
			return
		}
	},
)

Functions

This section is empty.

Types

type Service

type Service struct {
	// contains filtered or unexported fields
}

func NewService

func NewService(
	l *zap.Logger,
	deployment string,
	redis *redis.Client,
	url string,
	maxNum int,
	mq miface.MessageQueue,
	aParams mfx2.AppParams,
) (result *Service, err error)

func (*Service) RegisterWithGrpcServer

func (s *Service) RegisterWithGrpcServer(server siface.IGrpcServer) error

func (*Service) UpdateMail

func (s *Service) UpdateMail(ctx context.Context, request *pb.UpdateMailRequest) (*pb.UpdateMailResponse, error)

func (*Service) Watch

func (s *Service) Watch(req *pb.WatchMailRequest, server pb.MailService_WatchServer) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL