Skip to content

Avoid ORM over-hydration in GET /users/{username} - #2433

Draft
shangyian wants to merge 3 commits into
mainfrom
perf/user-nodes-hydration
Draft

Avoid ORM over-hydration in GET /users/{username}#2433
shangyian wants to merge 3 commits into
mainfrom
perf/user-nodes-hydration

Conversation

@shangyian

Copy link
Copy Markdown
Collaborator

Summary

Replace ORM Node/NodeRevision fetch (this has an unused cube_elements eager-load chain plus mapper-level selectin/joined loads on created_by, node, and catalog) with a column-only select scoped to exactly the fields the output model NodeMinimumDetail needs. Tags and edited_by are populated via targeted queries instead of relationship hydration.

Test Plan

  • PR has an associated issue: #
  • make check passes
  • make test shows 100% unit test coverage

Deployment Plan

Replace entity-loaded Node/NodeRevision fetch (with an unused cube_elements
eager-load chain plus mapper-level selectin/joined loads on created_by,
node, and catalog) with a column-only select scoped to exactly the fields
NodeMinimumDetail needs. Tags and edited_by are populated via targeted
queries instead of relationship hydration.
@netlify

netlify Bot commented Aug 21, 2026

Copy link
Copy Markdown

Deploy Preview for thriving-cassata-78ae72 canceled.

Name Link
🔨 Latest commit efdb240
🔍 Latest deploy log https://app.netlify.com/projects/thriving-cassata-78ae72/deploys/6a8856fceb978b00084abb95

@shangyian shangyian changed the title [perf] avoid ORM over-hydration in GET /users/{username} Avoid ORM over-hydration in GET /users/{username} Aug 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant