mailservice

package
v0.2.7 Latest Latest
Warning

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

Go to latest
Published: May 22, 2026 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

View Source
const (
	MaxRetries    = 3
	RetryInterval = time.Second * 5
	BatchSize     = 10
)

Variables

This section is empty.

Functions

func AddToQueue

func AddToQueue(task EmailTask) error

AddToQueue stores an email task for background processing.

func SendActivationEmail

func SendActivationEmail(to, username, token string) error

func SendPasswordResetEmail added in v0.0.9

func SendPasswordResetEmail(to, username, token string) error

SendPasswordResetEmail 发送密码重置邮件

func SendTestEmailWithConfig added in v0.0.8

func SendTestEmailWithConfig(config pageConfig.MailSettingsConfig, testEmail string) error

SendTestEmailWithConfig 使用指定配置发送测试邮件

func StartEmailProcessor

func StartEmailProcessor()

StartEmailProcessor starts the background email queue worker.

Types

type EmailTask

type EmailTask struct {
	To       string `json:"to"`
	Username string `json:"username"`
	Token    string `json:"token"`
	Type     string `json:"type"`
}

Jump to

Keyboard shortcuts

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