Questions
- How should we bounce messages? Silently? Via an auto-generated message?
- On an error, send an error message to the sender's inbox.
- How many recipients can be sent to at once?
How should we configure Amazon SES?
- Proposal:
- Reroute bounce and complaints to SNS
- Have a worker disable emails to hard-bounced recipients
- Also flip flags in settings for complaints
- Store the bounce/complaint in a blob
- Proposal:
- How should we implement the worker that sends messages?
- Proposal:
- Add a migratable table with a single column of message IDs
- Add a worker that periodically polls the table
- If the table is not empty, process N rows from the top
- Delete rows once finished processing
- Proposal:
- Should some messages be stored as templates?
- If we start sending out notifications about Entity changes and the like, most of the contents will be similar except for the ID and some small part of the message body. We could conceivably add a flag to the MessageToUser object that tells the client to fill in a messages according to some simple template. Then we could store the key-values of the template in a blob along with the message.
Objects
Name | DBO | Migration | DTO |
---|---|---|---|
(Immutable after creation) |
| Backup via ID Note: Etag is required because MessageStatus is mutable. | Interface
|
(Immutable after creation) |
| Secondary to MessageContent | Implements MessageContent
|
(Immutable after creation) |
| Secondary to MessageContent | |
|
| Secondary to MessageContent |
|
(Immutable after creation) |
| Secondary to MessageContent | Implements MessageContent
|
|
| TBD |
|
|
| TBD |
|
| Bundles the MessageToUser and Message Status | ||
|
|
'* per Marcel, Comments may have a more complex set of references/relationships than Messages to Users have. Rather than just 'inReplyTo', it might be that one Comment is an 'answer' to another comment which is a question. Further, the multiple answers to a question may have 'previous' references which order them.
Other
...
.
...
- Messages to a low number (1) of recipients should be immediately consistent
- Comments should always be immediately consistent
...
- Proposed RDS implementation
- Add a migratable table with a single column of message IDs
- Add a worker that periodically polls the table
- If the table is not empty, process N rows from the top
- Delete rows once finished processing
...
Services
- Sorting & Pagination
- Sort by creation date
- Sort by subject
- Sort by recipient name
...