Skip to content

Feature Data Storage

Timothy James Dobbins edited this page Oct 31, 2020 · 3 revisions

First thought is to use a sqlite db and keep everything simple and local.

Also considering using a cloud db (redshift, snowflake). Still weighting the pros/cons.

Current schema brainstorm:

Either way, use sqlalchemy models to make transactions easier.

db: DEWEY

tables: * tasks (tasks go in cards) * lists (lists go in boards) * cards (cards hold tasks and go in lists)

tasks are specified by dewey - custimizations cards have attributes from trello

cards have attributes from trello which will be stored in DEWEY.card. tasks have additional customizations which will be stored in DEWEY.task. lists have attributes from trello which will be stored in DEWEY.list.

Starting Schema: user_id -> board_id -> list_id -> [card_id - task_id]

Need a table to read in new cards? For instance, when a user creates a new card using the UI, when the backend reads it in, where should it be stored?

Should there be a task table for unique tasks? Then a card table for transactions? The task table will actually record information about the task like:

  • brush teeth will have attrs like: day_section, description, cadence, etc. These shouldn't be stored in the card table.

The Card table should be transactional and record what the state of each non-task attr is at a specific time.


Instead of deleting cards on reset, to be able to persist the state of cards cards will need to be removed from lists on pull and the same cards placed back on the appropriate list on push.

Clone this wiki locally