skalenetwork / filestorage

SKALE filestorage extension to EVM
GNU Affero General Public License v3.0
20 stars 3 forks source link

Add getter for storageSpace #55

Closed sync-by-unito[bot] closed 3 years ago

sync-by-unito[bot] commented 3 years ago

Add getter to reservedStorageSpace in filestorage

┆Issue is synchronized with this Jira Task

sync-by-unito[bot] commented 3 years ago

➤ Automation for Jira commented:

Corresponding Pull Request https://github.com/skalenetwork/filestorage/pull/56

sync-by-unito[bot] commented 3 years ago

➤ Ganna Kulikova commented:

Not required for the release

Dmytro Nazarenko to add more context

sync-by-unito[bot] commented 3 years ago

➤ Oleksandr Sydorenko commented:

Cannot reproduce this one on 1.0.0-develop.1 version Filestorage.js Need to recheck this issue when Dmytro Nazarenko will add getters to filestorage.js

sync-by-unito[bot] commented 3 years ago

➤ Automation for Jira commented:

Corresponding Pull Request https://github.com/skalenetwork/filestorage.js/pull/173

sync-by-unito[bot] commented 3 years ago

➤ Oleksandr Sydorenko commented:

Steps to reproduce: Run filestorage tests Call getTotalStorageSpace, getTotalReservedSpace, getReservedSpace, getOccupiedSpace methods

Blocked by https://skalelabs.atlassian.net/browse/SKALE-4590 ( https://skalelabs.atlassian.net/browse/SKALE-4590|smart-link )

sync-by-unito[bot] commented 3 years ago

➤ Automation for Jira commented:

Corresponding Pull Request https://github.com/skalenetwork/skale-node/pull/352

sync-by-unito[bot] commented 3 years ago

➤ Oleksandr Sydorenko commented:

Verified on components network Versions for test Skaled: 3.8.3-develop.0 filestorage.js 1.0.1-develop.1 ( https://www.npmjs.com/package/@skalenetwork/filestorage.js/v/1.0.1-develop.1 ) filestorage 1.0.1-develop.1 ( https://github.com/skalenetwork/filestorage/releases/download/1.0.1-develop.1/artifacts.json )

Steps to reproduce: run filestorage test with 4 getters (getTotalStorageSpace, getTotalReservedSpace, getReservedSpace, getOccupiedSpace methods)

Filestorage.js logs:

Space was allocated 1000000000000000000000000000000 getTotalSpace 6659997696 start: 2021-09-29T10:01:37.327Z before test getOccupiedSpace for b04a7f2Cd74Eb624Df4BD8bed8f7034B5Aed89C0 is 0 Ocupied space for 0c4b9D6997F2a9eD419c8743688c8b7720C8118 is 0 getReservedSpace for b04a7f2Cd74Eb624Df4BD8bed8f7034B5Aed89C0 is 300000000 getTotalReservedSpace 300000000 getTotalSpace 6659997696 Time: 2021-09-29T10:01:39.528Z ; iteration: 0 File was created! Chunk 0 was loaded 1048576 Checking file validity... File was uploaded! b04a7f2Cd74Eb624Df4BD8bed8f7034B5Aed89C0/loopTest.txt after upload getOccupiedSpace for b04a7f2Cd74Eb624Df4BD8bed8f7034B5Aed89C0 is 1048576 Ocupied space for 0c4b9D6997F2a9eD419c8743688c8b7720C8118 is 0 getReservedSpace for b04a7f2Cd74Eb624Df4BD8bed8f7034B5Aed89C0 is 300000000 getTotalReservedSpace 300000000 getTotalSpace 6659997696 File was deleted after deleting getOccupiedSpace for b04a7f2Cd74Eb624Df4BD8bed8f7034B5Aed89C0 is 0 Ocupied space for 0c4b9D6997F2a9eD419c8743688c8b7720C8118 is 0 getReservedSpace for b04a7f2Cd74Eb624Df4BD8bed8f7034B5Aed89C0 is 300000000 getTotalReservedSpace 300000000 getTotalSpace 6659997696filestorage dir on the node:

after upload total 1024 drwxr-xr-x 1 root root 24 Sep 29 10:10 ./ drwxr-xr-x 1 root root 80 Sep 29 09:45 ../ rwr--r-- 1 root root 1048576 Sep 29 10:10 loopTest.txt

after cleanup

total 0 drwxr-xr-x 1 root root 0 Sep 29 10:36 ./ drwxr-xr-x 1 root root 80 Sep 29 09:45 ../