Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BUGFIX 4508 mark dependands of live outdated after direct change #5274

Merged

Conversation

mhsdesign
Copy link
Member

FIXES: #4508

Upgrade instructions

Review instructions

Checklist

  • Code follows the PSR-2 coding style
  • Tests have been created, run and adjusted as needed
  • The PR is created against the lowest maintained branch
  • Reviewer - PR Title is brief but complete and starts with FEATURE|TASK|BUGFIX
  • Reviewer - The first section explains the change briefly for change-logs
  • Reviewer - Breaking Changes are marked with !!! and have upgrade-instructions

Comment on lines 60 to 62
{$this->tableNames->workspace()} ws
JOIN {$this->tableNames->contentStream()} cs ON cs.id = ws.currentcontentstreamid
LEFT JOIN {$this->tableNames->contentStream()} scs ON cs.sourceContentStreamId = scs.id
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

so the performance trait is this: we still have the status in the workspace, but we have to calculate it slightly more expensive with these two joins.
I cannot say if this is better performance than having on the write side a similar complex update logic for each event. But as findWorkspaceByName (and implicitly getContentGraph) trigger this query and are also part of the write side for constraint checks we have to carefully evaluate.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

At some point the content graph projections needs to know about changes between streams/workspaces (e.g. to count/diff pending changes etc). Then we can revisit this topic and make it faster if needed

@mhsdesign mhsdesign force-pushed the task/add-workspace-contentstream-mapping-to-contentgraph branch from c374314 to db7861f Compare October 10, 2024 08:20
Base automatically changed from task/add-workspace-contentstream-mapping-to-contentgraph to 9.0 October 17, 2024 11:11
@github-actions github-actions bot added the 9.0 label Oct 17, 2024
@mhsdesign mhsdesign force-pushed the bugfix/4508-mark-dependands-of-live-outdated-after-direct-change branch from f928255 to 26e2de7 Compare October 17, 2024 12:21
@mhsdesign mhsdesign marked this pull request as ready for review October 17, 2024 12:24
Copy link
Member

@bwaidelich bwaidelich left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great already, just a comment regarding "expected version"

…oid fetching full workspace model

with the extra joins in the workspace model it is just easier to just select the current content stream id directly
Copy link
Member

@nezaniel nezaniel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks nice

@mhsdesign mhsdesign merged commit a21f159 into 9.0 Oct 24, 2024
3 of 4 checks passed
@mhsdesign mhsdesign deleted the bugfix/4508-mark-dependands-of-live-outdated-after-direct-change branch October 24, 2024 14:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

BUG: Running ./flow structureadjustments:fix doesn't mark workspaces as outdated
4 participants