-
Notifications
You must be signed in to change notification settings - Fork 54.3k
chore(editor): Remove all calls to fetch all users and replace with targeted filtering #25024
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
base: master
Are you sure you want to change the base?
chore(editor): Remove all calls to fetch all users and replace with targeted filtering #25024
Conversation
…on project navigation
…for project settings user selection
047f920 to
93234f9
Compare
Codecov Report❌ Patch coverage is 📢 Thoughts on this report? Let us know! |
This comment has been minimized.
This comment has been minimized.
Bundle ReportChanges will increase total bundle size by 40.94MB (100.0%) ⬆️
|
Bundle ReportChanges will increase total bundle size by 40.98MB (100.0%) ⬆️
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
1 issue found across 17 files
Prompt for AI agents (all issues)
Check if these issues are valid — if so, understand the root cause of each and fix them.
<file name="packages/frontend/editor-ui/src/features/workflows/workflowHistory/views/WorkflowHistory.vue">
<violation number="1" location="packages/frontend/editor-ui/src/features/workflows/workflowHistory/views/WorkflowHistory.vue:117">
P1: Rule violated: **Prefer Typeguards over Type casting**
Replace the type assertion with a type guard. Rule 1 forbids `as` for type narrowing; use a predicate to narrow to string instead.</violation>
</file>
Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.
Summary
Addresses performance degradation when working with large user lists by removing unlimited database queries (take: -1) and implementing proper filtering.
Changes
Backend:
Add filter capabilities (by ids, or by pending state) on the users controller to enable better filter targeting on the front.
Editor:
Added remote, remoteMethod, and loading props for paginated user loading. Maintains backwards compatibility with local filtering mode.
Removed useless calls to users.
Transformed global fetch of all users to targeted fetch with filtering
Related Linear tickets, Github issues, and Community forum posts
https://linear.app/n8n/issue/IAM-158/community-issue-performance-degradation-while-big-users-count
Review / Merge checklist
release/backport(if the PR is an urgent fix that needs to be backported)