-
Notifications
You must be signed in to change notification settings - Fork 4
[_] feat: allow empty files in workspace #833
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?
Conversation
|
|
This PR is stale because it has been open for more than 15 days with no activity. |
2b284d1 to
2b1bd8a
Compare
|
c68879d to
36d20c6
Compare
| include: [ | ||
| { | ||
| model: WorkspaceItemUserModel, | ||
| where: { |
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.
Does an index exist for this?
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.
based on the following explain result yes
| QUERY PLAN |
|---|
| Aggregate (cost=5.05..5.06 rows=1 width=8) |
| -> Nested Loop (cost=1.00..5.05 rows=1 width=4) |
| -> Index Scan using workspace_items_users_workspace_creator_index on workspace_items_users "workspaceUser" (cost=0.42..2.45 rows=1 width=16) |
| Index Cond: ((workspace_id = '<worksapce uuid>'::uuid) AND ((created_by)::text = '<workspace user uuid>'::text)) |
| Filter: ((item_type)::text = 'file'::text) |
| -> Index Scan using files_uuid_key on files "FileModel" (cost=0.57..2.60 rows=1 width=20) |
| Index Cond: (uuid = "workspaceUser".item_id) |
| Filter: ((status <> 'DELETED'::enum_files_status) AND (size = 0)) |
…backup, file, and folder use cases
…o deleted folders
…o prevent null file_id entries
…ic logging and response
…ce network user empty file counts
93ad14e to
fe03a53
Compare



Introduces per-member empty file limit checks when creating files in a workspace. The limit is enforced inside fileUseCases.createFile using the same workspaceOptions pattern already used by replaceFile, ensuring the check runs against the individual workspace member rather than the shared network user.