client

package
v0.0.0-...-7690d25 Latest Latest
Warning

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

Go to latest
Published: Sep 24, 2021 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	CONNECTIONSTRING = bouncemailcounter.Load().MongoUri
	DB               = bouncemailcounter.Load().MongoDataBase
	MailLogs         = bouncemailcounter.Load().MongoCollection
)

Functions

func ConvertToTimeMST

func ConvertToTimeMST(time_str string) time.Time

func CreateLog

func CreateLog(task MailLog) error

func GetMongoClient

func GetMongoClient() (*mongo.Client, error)

func SendTele

func SendTele(message []byte) []byte

func UpdateLog

func UpdateLog(queue_id string, key string, value string) error

Types

type MailLog

type MailLog struct {
	Queue_Id              string    `bson:"queue_id"`
	From                  string    `bson:"from"`
	To                    string    `bson:"to"`
	Message_Id            string    `bson:"message_id"`
	Recipient_Smtp_Ip     string    `bson:"recipient_smtp_ip"`
	Recipient_Smtp_Domain string    `bson:"recipient_smtp_domain"`
	Status                string    `bson:"status"`
	Message               string    `bson:"message"`
	Sent_At               time.Time `bson:"sent_at"`
}

func GetLogByQueueId

func GetLogByQueueId(queue_id string) (MailLog, error)

func GetManyLogs

func GetManyLogs(key string, value string, from_date time.Time, to_date time.Time) ([]MailLog, error)

Jump to

Keyboard shortcuts

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