You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by "dentiny (via GitHub)" <gi...@apache.org> on 2026/04/05 03:25:01 UTC

[I] BUG: in-memory storage loss part on upload [arrow-rs-object-store]

dentiny opened a new issue, #682:
URL: https://github.com/apache/arrow-rs-object-store/issues/682

   **Describe the bug**
   Hi team, IIRC, if we upload parts out of order, the parts received will be dropped.
   https://github.com/apache/arrow-rs-object-store/blob/0fda34c5e0c00a7665649bd676c2d3d885ad3e20/src/memory.rs#L436-L438
   
   **To Reproduce**
   ```rust
   /// Test that MultipartStore::put_part works correctly when parts are
       /// uploaded out of order, which is explicitly permitted by the API contract.
       /// See [`MultipartStore::put_part`] docs: "Parts may be uploaded concurrently
       /// and in any order."
       #[tokio::test]
       async fn multipart_out_of_order_put_part() {
           use crate::multipart::MultipartStore;
   
           let store = InMemory::new();
           let path = Path::from("test_out_of_order");
   
           let upload_id = store.create_multipart(&path).await.unwrap();
   
           // Upload part 2 first (before parts 0 and 1)
           let part2_data = PutPayload::from(Bytes::from("part2"));
           let part2 = store
               .put_part(&path, &upload_id, 2, part2_data)
               .await
               .unwrap();
   
           // Then upload part 0
           let part0_data = PutPayload::from(Bytes::from("part0"));
           let part0 = store
               .put_part(&path, &upload_id, 0, part0_data)
               .await
               .unwrap();
   
           // Then upload part 1
           let part1_data = PutPayload::from(Bytes::from("part1"));
           let part1 = store
               .put_part(&path, &upload_id, 1, part1_data)
               .await
               .unwrap();
   
           // Complete the upload
           let result = store
               .complete_multipart(&path, &upload_id, vec![part0, part1, part2])
               .await
               .unwrap();
           assert!(result.e_tag.is_some(), "Expected e_tag in PutResult");
   
           // Verify the data was assembled correctly
           let data = store.get(&path).await.unwrap().bytes().await.unwrap();
           assert_eq!(data.as_ref(), b"part0part1part2");
       }
   ```
   
   **Expected behavior**
   Uploaded parts shouldn't be lost
   
   **Additional context**
   N/A


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] BUG: in-memory storage loss part on upload [arrow-rs-object-store]

Posted by "crepererum (via GitHub)" <gi...@apache.org>.
crepererum closed issue #682: BUG: in-memory storage loss part on upload
URL: https://github.com/apache/arrow-rs-object-store/issues/682


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org