MishkaDocument. Resources. Changes. SetSectionLineageId
(Mishka Document v0.0.1)
Copy Markdown
View Source
Automatically sets section_lineage_id for tracking section versions across workspace versions.
- New sections (no source): section_lineage_id = the section's own id
- Cloned sections (has source): section_lineage_id = source's section_lineage_id, copied as the write runs, after its validations. It may name a first section that has since been deleted; a first section of another site is refused.
- A section_lineage_id the writer gives is kept, and must name a section of the same site.
Looking up the source and the lineage's first section sees every site, because a pointer into another site is what is refused. A section that starts its own lineage has it written with the row, so creating a section is one event in the log, not a create followed by an update nobody made.