Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

NameDBOMigration

DTO

MessageContent

(Immutable after creation)

ID (PK)

Etag

MessageBody (S3 File Handle ID)

CreatedOn

CreatedBy (FK to JDOUSERGROUP)

InReplyTo (FK to ID column) (nullable)

backUpID is ID

Note:  Etag is required because MessageStatus is mutable

interface (superclass represented as JSON schema)

  • ID (derived from ID generator)
  • CreatedBy (principal ID) (upon creation filled in for the authenticated user)
  • RecipientBundle
    • List of recipient IDs
  • S3 File Handle ID
  • CreatedOn
  • inReplyTo* (optional)

MessageToUser

(Immutable after creation)

MessageContentID (FK to MessageContent)

Subject (nullable)

Secondary to MessageContent

backUpID is MessageContentID

implements MessageContent

Subject (string, optional)

MessageRecipient

(Immutable after creation)

FK to MessageContent

FK to JDOUSERGOUP

Secondary to MessageContent

backUpID is MessageContentID
n/a

MessageStatus

  • Foreign key: MessageContentID
  • Foreign key: Recipient ID (UserGroup)
  • States: UNREAD, READ, ARCHIVED
 

Secondary to MessageContent

backUpID is MessageContentID
  • ID
  • Recipient
  • State

Comment

(Immutable after creation)

MessageContentID (FK to MessageContent)

TargetType (Enum ObjectType)

TargetID

 

Secondary to MessageContent

backUpID is MessageContentID
implements MessageContent

MessageInReplyToRoot

(Immutable after creation)

  • Primary key: MessageContentID (FK to MessageContent)
  • Foreign key: InReplyToRootID
    • Recursive foreign key to primary key
 

Secondary to MessageContent

backUpID is MessageContentID
n/a
  •  Message votes
  • Primary key: Message ID
  • Up votes
  • Down votes
 
  • ID
  • Up
  • Down
  •  MessageSettings
  • Foreign key: User ID (UserGroup)
  • Etag
  • Blob of settings
 
  • ID
  • Notification levels
    • Update to an owned entity
    • Update to some favorite entity
    • Team
    • Message from user
    • Mail to everyone
    • Etc...
  • Message receipt email (if more than one)
  • Auto-mark mail as read if forwarded to email
  •  MessageBundle
  Bundles the Message and Message Status
  •  RecipientBundle
  
  • RecipientType
    • May be a principal, entity, ...
  • Array of IDs
    • All IDs must be valid (404 otherwise)

...