Use WinFS-style graph model instead of block tree model #392
Replies: 2 comments
-
owner @aligo |
Beta Was this translation helpful? Give feedback.
-
Combining the WinFS-style model with our next phase Project Q, to achieve Resources(Objects):
Notes:
Links:
Notes:
Because under the current architecture, data used/operated in the client is actually built based on state (rather than States(of Object)
|
Beta Was this translation helpful? Give feedback.
-
Problem
Articulate the problem that this piece of work addresses. What is the status quo and why does that not work? Why does the problem matter?
We currently use a Tree structure to store the parent-child relationships between blocks and add additional tables to store structure data such as formulas. This structure is not enough for no-code and automation workflow scenarios. There may be several types of relationships between different blocks or between blocks and other structural data. For example, what content a PageBlock contains, what the parent Page of a PageBlock is, and to which PageBlocks a PageBlock is backlinked are all different types of relationships.
We can build a generic model to represent the relationship between different data.
Why is this the right time to address this problem?
As a refactoring of the core, this epic needs to be completed early to reduce compatibility issues.
Time Budget
2 weeks
Solution
Resource will be used as a generic term for blocks, formulas and other structured data.
ResourceSchema
.Resource
model instead of the DocsBlock and DocsFormula models.ResourceLink
model withsubject
,predicate
andobject
fields.predicate
is an enum value that can be contents, link, parentPage, etc.Out of Bounds
For the time being we will only refactor the database schema and model, the GraphQL API will remain unchanged. And the tables
active_storage_attachments
,docs_share_links
, etc remain unchanged for the time being.Rabbitholes
Ref
Beta Was this translation helpful? Give feedback.
All reactions