-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: ✨ MSP stop storing buckets for insolvent user task (#366)
* refactor: ⚡ update move bucket requests for clarity and storage efficiency * chore: 🏷️ run typegen * fix: 🐛 remove `previous_msp_id` from move bucket request metadata This change is made since a bucket status (such as its MSP) could change between the request was made and the new MSP responds, so it's not reliable * feat: 🚧 initial impl of stop storing bucket for insolvent user * chore: 🎨 run cargo fmt * fix: 🚨 update file system benchmark * fix: 🩹 update `get_provider_id` call * chore: 🏷️ run typegen * test: ✅ add tests for `msp_stop_storing_bucket_for_insolvent_user` * test: ✅ fix testing * chore: 🏷️ run typegen * fix: 🐛 add solvency check when issuing storage requests Added a check to make sure the payment stream between the MSP and the user exists when the user issues a new storage request. This is so we don't allow users that just stopped being insolvent to issue storage requests for buckets that the MSP hasn't deleted yet * chore: 🏷️ run typegen * feat: ✨ add task for MSP to stop storing buckets of insolvent user * fix: 🐛 avoid the task processing multiple times the same bucket * fix: 🐛 get only buckets stored by the current MSP (instead of all) * perf: ⚡ remove unneeded fetch from indexer db * feat: 📈 benchmark file system * perf: ⚡ drop file write lock asap * test: ✅ add integration test for MSP stop storing bucket for insolvent user * chore: 🏷️ Update api-augment after merge * fix: 🚨 Fix compiler errors in test after merge * refactor: ♻️ Rename `MoveBucketRequestedForNewMsp` -> `MoveBucketRequestedForMsp` * fix: 🩹 fix after merge from main * chore: 🏷️ Update `api-augment` after merge * fix: 🩹 Fix typo * fix: 🩹 minor fixes after merge from main * docs: 💡 Minor improvement of doc comment of task * impl query_buckets_for_insolvent_user runtime api in favor of querying index db for buckets stored by insolvent users * remove `get_by_msp_id_and_owner` indexer db function. remove `ProcessStopStoringForInsolventUserRequest` event processing from `MspStopStoringInsolventUserTask` * refactor: 🔥 remove now unneeded handling of `MspStopStoringBucketInsolventUser` event * refactor: ⚡ make stop storing buckets for insolvent user task parallelizable * test: ✅ fix integration test after changes * test: 🔥 remove `only` from MSP stop storing bucket for insolvent user integration test * Update node/src/tasks/msp_stop_storing_insolvent_user.rs Co-authored-by: Facundo Farall <37149322+ffarall@users.noreply.github.com> * chore: 🏷️ run typegen --------- Co-authored-by: Facundo Farall <37149322+ffarall@users.noreply.github.com> Co-authored-by: Michael Assaf <michael.assaf.edge@gmail.com> Co-authored-by: Michael Assaf <94772640+snowmead@users.noreply.github.com>
- Loading branch information
1 parent
bfc03d2
commit 832b228
Showing
25 changed files
with
1,050 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.