-
Notifications
You must be signed in to change notification settings - Fork 26
createDir function #190
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
createDir function #190
Conversation
|
For file upload blobber first puts the file in temporary directory for certain time and only upon commit transaction the file is moved to permanent directory. |
|
This is great! A much needed feature If I understand right though, this action does not need committed? In terms of payment, an empty directory technically takes up some space in the file system table but ultimately is empty - should blobbers be paid for an empty directory? |
|
Blobbers do not charge for rename, share, delete, copy, move, add-collab, and emptyDir creation. Blobbers do carry the cost of commit transactions to the chain but we expect that to be minimal. If there is an crud attack, the Blobbers can reduce the commit frequency. |
| newDir.Name = dirName | ||
| newDir.Size = 2 | ||
| newDir.NumBlocks = 2 | ||
| newDir.ParentPath = dirRef.Path |
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.
I think it should be
newDir.ActualFileSize = 0
newDir.Size = 0
newDir.NumBlocks = 0
Possibility to create dir without files inside
zbox createdir --allocation dd60f818349bac486f95780a2024c3c17e6e4fa598cd324206381d4cd6733f85 --dirname /test777zbox list-all --allocation dd60f818349bac486f95780a2024c3c17e6e4fa598cd324206381d4cd6733f85Will include new dir
"name":"test777","num_of_blocks":2,"path":"/test777","path_hash":"a7ffc6f8bf1ed76651c14756a061d662f580ff4de43b49fa82d80a4b80f8434a","size":2,"type":"d","updated_at":"2021-07-12T15:06:05.419607Z"}