Skip to content

WIP: BUGFIX: Speed up findChildNodes in a large content repository#5728

Draft
mhsdesign wants to merge 1 commit intoneos:9.0from
mhsdesign:bugfix/speedup-find-child-nodes-content-graph
Draft

WIP: BUGFIX: Speed up findChildNodes in a large content repository#5728
mhsdesign wants to merge 1 commit intoneos:9.0from
mhsdesign:bugfix/speedup-find-child-nodes-content-graph

Conversation

@mhsdesign
Copy link
Copy Markdown
Member

@mhsdesign mhsdesign commented Jan 10, 2026

see https://discuss.neos.io/t/discussion-editing-and-storing-thousands-of-blog-posts-news-entries-in-nodes-in-neos-9-0/7154 for the full discussion

a query always uses both the 'parentnodeanchor' and 'childnodeanchor' column thus we group them into a single (unique) index (we can simply use them as primary key)

the position is now an own index otherwise EXPLAIN SELECT shows that the default ordering h.position ASC is not done via index

this is merely the index adjustment. The queries must be adjusted as well to leverage subselects wich brings the full performance gain with the new indexes

Ironically we had the primary key like this already but reverted that change #5009 because of slow replay performance. That will need to be reevaluated. See #5011 (comment)

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

a query always uses both the 'parentnodeanchor' and 'childnodeanchor' column thus we group them into a single (unique) index (we can simply use them as primary key)

the position is now an own index otherwise `EXPLAIN SELECT` shows that the default ordering `h.position ASC` is not done via index

this is merely the index adjustment. The queries must be adjusted as well to leverage subselects wich brings the full performance gain with the new indexes
@mhsdesign mhsdesign marked this pull request as draft January 10, 2026 12:44
@github-actions github-actions bot added the 9.0 label Jan 10, 2026
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.

1 participant