Thanks to visit codestin.com
Credit goes to github.com

Skip to content

oracleobjectstorage: fix: upload empty streams without multipart - #9903

Open
tomaszni wants to merge 1 commit into
rclone:masterfrom
tomaszni:fix-oracleobjectstorage-empty-stream
Open

oracleobjectstorage: fix: upload empty streams without multipart#9903
tomaszni wants to merge 1 commit into
rclone:masterfrom
tomaszni:fix-oracleobjectstorage-empty-stream

Conversation

@tomaszni

Copy link
Copy Markdown
Contributor

What does this change do?

Fix the Oracle Object Storage FsPutStream/0 integration-test failure.

OCI rejects completion of a multipart upload with no parts. For an unknown-size stream, probe through a buffered reader; if it is already at EOF, use a regular upload instead. Peek preserves non-empty stream data for the selected upload path.

The separate companion PR #9902 fixes the Oracle Object Storage FsEncoding failures. Together, these two trivial fixes address the remaining failures from the backend integration suite.

Linked issue

No issue - trivial backend bug fix.

For new or changed backends

Tested against a configured Oracle Object Storage remote:

go test -v -run '^TestIsZeroLength$' ./backend/oracleobjectstorage
go test -v -run 'TestIntegration/FsMkdir/FsPutFiles/FsPutStream' ./backend/oracleobjectstorage

The focused unit test passes all isZeroLength paths. The integration test passes both zero-byte and 100-byte streamed uploads.

A full backend run on this branch still has the separate FsEncoding failure, addressed by #9902.

Checklist

OCI rejects a multipart completion request with no parts. Probe unknown-size streams through a buffered reader and use a regular upload when the stream is empty. Peek preserves a non-empty stream for the selected upload path.
@tomaszni
tomaszni force-pushed the fix-oracleobjectstorage-empty-stream branch from 21c04e1 to 3e424e1 Compare September 13, 2026 11:59
@tomaszni

Copy link
Copy Markdown
Contributor Author

Rebased on current master and removed test_all ignore for the fixed test.

@tomaszni tomaszni changed the title oracleobjectstorage: upload empty streams without multipart oracleobjectstorage: fix: upload empty streams without multipart Sep 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant