Fixes for split-related EC queries #1163

Merged
dstepanov-yadro merged 1 commit from fyrchik/frostfs-node:fix-last-part into master 2024-09-04 19:51:08 +00:00
Owner
  1. Allow searching by splitID
  2. Allow to get last part in the SplitInfo.

Tested on dev-env

$ frostfs-cli object head -w ./wallets/wallet.json -r s02.frostfs.devenv:8080 --cid HTq9uqN8afseqLvNWPe5n3X8kgX6WWb9X9aPSw7sBZ7x --oid 4uimMGYdaKHq3JypXsZkVTptzUzNGE6Z86z9wczPsn79 --ttl=1 --raw
Enter password >
Object is complex, split information received.
Split ID: e085aa2f-48ab-454a-99cb-eade42e64358
Linking object: Aj7pw6sZraC84LeHhhUvBqKbNZzRKgQqCpn1PVNbvHLN
Last object: 8EbnT7y2urj3mbsB1Gn6WW1G87kRsxDHW6g5m1sB6oKU

$ frostfs-cli object search -w ./wallets/wallet.json -r s01.frostfs.devenv:8080 --cid HTq9uqN8afseqLvNWPe5n3X8kgX6WWb9X9aPSw7sBZ7x --ttl=1 --filters '$Object:split.splitID EQ e085aa2f-48ab-454a-99cb-eade42e64358'
Enter password >
Found 3 objects.
5PSMCc8FGuK7uPFJGcbQ4qkM2VNXSufP3aQHGKnsPzUk
8EbnT7y2urj3mbsB1Gn6WW1G87kRsxDHW6g5m1sB6oKU
Aj7pw6sZraC84LeHhhUvBqKbNZzRKgQqCpn1PVNbvHLN
1. Allow searching by splitID 2. Allow to get last part in the SplitInfo. Tested on dev-env ``` $ frostfs-cli object head -w ./wallets/wallet.json -r s02.frostfs.devenv:8080 --cid HTq9uqN8afseqLvNWPe5n3X8kgX6WWb9X9aPSw7sBZ7x --oid 4uimMGYdaKHq3JypXsZkVTptzUzNGE6Z86z9wczPsn79 --ttl=1 --raw Enter password > Object is complex, split information received. Split ID: e085aa2f-48ab-454a-99cb-eade42e64358 Linking object: Aj7pw6sZraC84LeHhhUvBqKbNZzRKgQqCpn1PVNbvHLN Last object: 8EbnT7y2urj3mbsB1Gn6WW1G87kRsxDHW6g5m1sB6oKU $ frostfs-cli object search -w ./wallets/wallet.json -r s01.frostfs.devenv:8080 --cid HTq9uqN8afseqLvNWPe5n3X8kgX6WWb9X9aPSw7sBZ7x --ttl=1 --filters '$Object:split.splitID EQ e085aa2f-48ab-454a-99cb-eade42e64358' Enter password > Found 3 objects. 5PSMCc8FGuK7uPFJGcbQ4qkM2VNXSufP3aQHGKnsPzUk 8EbnT7y2urj3mbsB1Gn6WW1G87kRsxDHW6g5m1sB6oKU Aj7pw6sZraC84LeHhhUvBqKbNZzRKgQqCpn1PVNbvHLN ```
fyrchik force-pushed fix-last-part from 989f1ea63a to 6a5298a89b 2024-06-05 09:40:30 +00:00 Compare
fyrchik changed title from Fixes for split-related EC queries to WIP: Fixes for split-related EC queries 2024-06-05 09:40:32 +00:00
fyrchik requested review from storage-core-committers 2024-06-05 09:40:53 +00:00
fyrchik requested review from storage-core-developers 2024-06-05 09:41:09 +00:00
Author
Owner

For some reason, last part is not fetched from each node (which I would expect), investigating.

For some reason, last part is not fetched from each node (which I would expect), investigating.
fyrchik force-pushed fix-last-part from 6a5298a89b to c1cdd5d408 2024-06-06 08:25:08 +00:00 Compare
fyrchik changed title from WIP: Fixes for split-related EC queries to Fixes for split-related EC queries 2024-06-06 08:28:52 +00:00
Author
Owner

The bug was in race condition when both linking object and the last part were put on one shard.

The bug was in race condition when both linking object and the last part were put on one shard.
fyrchik force-pushed fix-last-part from c1cdd5d408 to f9efa85cbd 2024-06-06 08:30:45 +00:00 Compare
fyrchik added the
bug
label 2024-06-06 08:32:35 +00:00
fyrchik added this to the v0.41.0 milestone 2024-06-06 08:32:41 +00:00
dstepanov-yadro requested changes 2024-06-06 08:40:02 +00:00
@ -405,3 +414,3 @@
}
func putUniqueIndexItem(tx *bbolt.Tx, item namedBucketItem) error {
func updateUniqueIndexItem(tx *bbolt.Tx, item namedBucketItem, update func(oldSI, newSI []byte) ([]byte, error)) error {

update func(oldSI, newSI []byte) -> update func(oldData, newData []byte) or something else, but not SI

`update func(oldSI, newSI []byte)` -> `update func(oldData, newData []byte)` or something else, but not `SI`
Author
Owner

Fixed

Fixed
acid-ant approved these changes 2024-06-06 12:27:15 +00:00
fyrchik force-pushed fix-last-part from f9efa85cbd to 3f1961157e 2024-06-06 13:26:47 +00:00 Compare
dstepanov-yadro approved these changes 2024-06-06 14:40:33 +00:00
acid-ant approved these changes 2024-06-06 14:44:43 +00:00
dstepanov-yadro merged commit 3f1961157e into master 2024-06-06 15:04:08 +00:00
fyrchik deleted branch fix-last-part 2024-06-06 15:23:50 +00:00
Sign in to join this conversation.
No reviewers
TrueCloudLab/storage-core-developers
No milestone
No project
No assignees
3 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: TrueCloudLab/frostfs-node#1163
No description provided.