Skip to content
This repository has been archived by the owner on Apr 3, 2024. It is now read-only.
Daniel J. Summers edited this page Oct 6, 2016 · 5 revisions

Data Model

Overview

For our data model, we will begin with how we will store it. At a high level:

  • Web logs have a name, an optional subtitle, a theme, a URL, and a time zone
  • Users have an e-mail address, a password, a first name, a last name, a preferred name, and a personal URL
  • Categories have a name, a URL-friendly "slug", and a description
  • Posts have a title, a status, a permalink, when they were published and last updated, 0 or more tags, the text of the post, and a list of revisions of that post
  • Pages have a title, a permalink, when they were published and last updated, whether they should show in the default page list (think "About", "Contact", etc.), the text of the page, and a list of revisions to that page
  • Comments have a name, an e-mail address, an optional URL, a status, when they were posted, and the text of the comment

As far as relationships among these entities:

  • Users can have differing authorization levels among the different web logs to which they are authorized
  • Categories, Posts, and Pages all each belong to a specific web log
  • Comments belong to a specific Post
  • Posts are linked to the user who authored them
  • Categories can be nested (parent/child)
  • Comments can be marked as replies to another comment
  • Posts can be assigned to multiple Categories (and can have multiple Comments, as implied above)
  • Revisions (Posts and Pages) will track the date/time of the revision and the text of the post or page as of that time

Both Uno and Dos will use the same C# model. For Tres, we'll convert classes to F# record types (and null checks to Options). For Quatro, if the storage driver supports it (research ongoing), we'll look at making concrete types for some of these primitives, making it more difficult to represent an invalid state within our model.

Implementation Notes

TODO:

Clone this wiki locally