mirror of
https://github.com/knadh/listmonk.git
synced 2024-09-20 15:26:33 +08:00
1a39ed15ec
When a campaign exceeds N number of message send errors, for instance SMTP errors, it is now auto-paused until there is manual intervention. For this, the master goroutine in runner.Run() that was synchronising between the tick based DB scanner and subscriber fetching has been split into two. A new queue aggregates send errors from workers again a threshold after which the campaign is paused.
15 lines
316 B
Python
15 lines
316 B
Python
import csv
|
|
import random
|
|
|
|
f = open("/tmp/subs.csv", "w+")
|
|
w = csv.writer(f)
|
|
w.writerow(["email", "name", "status", "attributes"])
|
|
|
|
for n in range(0, 100000):
|
|
w.writerow([
|
|
"user%d@mail.com" % (n,),
|
|
"First%d Last%d" % (n, n),
|
|
"enabled",
|
|
"{\"age\": %d, \"city\": \"Bangalore\"}" % (random.randint(20,70),)
|
|
])
|