Page MenuHomePhabricator

[services] Backup - Blob Get Client - Refactor put terminate
ClosedPublic

Authored by karol on Sep 9 2022, 4:43 AM.
Tags
None
Referenced Files
F5336341: D5093.id16851.diff
Wed, Apr 9, 12:11 AM
F5336338: D5093.id16842.diff
Wed, Apr 9, 12:11 AM
F5336334: D5093.id16810.diff
Wed, Apr 9, 12:11 AM
F5336330: D5093.id16574.diff
Wed, Apr 9, 12:11 AM
F5336327: D5093.id16545.diff
Wed, Apr 9, 12:11 AM
F5336324: D5093.id.diff
Wed, Apr 9, 12:11 AM
F5336320: D5093.diff
Wed, Apr 9, 12:11 AM
F5313753: D5093.id16842.diff
Tue, Apr 8, 2:26 PM

Details

Summary

Depends on D5092

Linear task: https://linear.app/comm/issue/ENG-1734/improve-error-handling-system-in-the-blob-client

Using a new way of error handling in the terminate method of the put client.

Test Plan
cd services/backup/blob_client
cargo check

after running localstack, blob and backup (in this particular order), this still works:

yarn run-performance-tests backup

Diff Detail

Repository
rCOMM Comm
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

jon requested changes to this revision.Sep 9 2022, 10:52 AM
jon added inline comments.
services/backup/blob_client/src/put_client.rs
59 ↗(On Diff #16545)

what's the purpose of holder?

also &String should always be &str in function inputs, as String and &String should be able to AsRef into a &str.

This revision now requires changes to proceed.Sep 9 2022, 10:52 AM
services/backup/blob_client/src/put_client.rs
59 ↗(On Diff #16545)

By holder we're identifying the client we're referring to.

Sure, we can use &str.

This revision is now accepted and ready to land.Sep 12 2022, 9:05 AM
tomek requested changes to this revision.Sep 15 2022, 8:46 AM
tomek added inline comments.
services/backup/blob_client/src/put_client.rs
36 ↗(On Diff #16574)

What does this comment mean?

59 ↗(On Diff #16574)

D5090 introduces is_initialized_new(holder: &String) function, later in the stack in D5092 this function is deleted and is_initialized(holder: &str) is used instead, but then this diff introduces is_initialized_new again but with a different parameter type. Something is wrong here.

This revision now requires changes to proceed.Sep 15 2022, 8:46 AM
services/backup/blob_client/src/put_client.rs
36 ↗(On Diff #16574)

should be removed

59 ↗(On Diff #16574)

You missed that the 2 diffs you mentioned do changes in get client and this diff does changes in put client. So I don't put something back again really.

tomek added inline comments.
services/backup/blob_client/src/put_client.rs
59 ↗(On Diff #16574)

Ahhh, ok. Sorry for the confusion!

This revision is now accepted and ready to land.Sep 19 2022, 5:07 AM
This revision was landed with ongoing or failed builds.Sep 19 2022, 7:28 AM
This revision was automatically updated to reflect the committed changes.