| |
| /pliant/protocol/smtp/meta.pli |
| |
| 1 |
abstract | |
| 2 |
['MailMeta' defines the small database that goes with a mail that his not delivered yet.] | |
| 3 |
| |
| 4 |
submodule "/pliant/storage/database.pli" | |
| 5 |
| |
| 6 |
public | |
| 7 |
| |
| 8 |
type MailMetaTarget | |
| 9 |
field Str box | |
| 10 |
field Char status <- " " # S=sent, R=rejected | |
| 11 |
field Int try_count <- 0 # how many time did we try | |
| 12 |
field DateTime last_try | |
| 13 |
field Str last_server | |
| 14 |
field Str last_error | |
| 15 |
| |
| 16 |
type MailMeta | |
| 17 |
field Str from | |
| 18 |
field Set:MailMetaTarget target | |
| 19 |
field Str route | |
| 20 |
field Bool direct <- true # forward only to the first server listed in the DNS | |
| 21 |
field Bool split <- false | |
| 22 |
field Int threads <- 1 | |
| 23 |
field DateTime queued_on | |
| 24 |
field Int try_times <- 10 # how many times must we try, at least | |
| 25 |
field Float try_period <- 7*86400 # how long will we try, at least, in second | |
| 26 |
field Bool report <- true # if some targets fail, must we send back a report | |
| 27 |
| |
| 28 |
| |
| 29 |
method m push | |
| 30 |
arg_rw Data:MailMeta m | |
| 31 |
m split := true | |
| 32 |
m threads := 5 | |
| 33 |
m try_times := 3 | |
| 34 |
m try_period := 86400 | |
| 35 |
m report := false | |
| 36 |
| |
| |