Repository navigation
feat(storage): add bounded conditional-create uploads - #371
primetimeindy wants to merge 3 commits into
Conversation
Expose opt-in SDK ifAbsent and CLI --if-absent for single-part uploads up to 5 MiB, preserving existing defaults. Assisted-by: GPT-6.1-sol via Hermes Agent
Assisted-by: GPT-6.1-sol via Hermes Agent
Export existing memfs descriptor APIs and add lock-exact SDK, native CLI, and browser-shim regression tests. Assisted-by: GPT-6.1-sol via Hermes Agent
|
The current head, 72d7077, includes the browser shim compatibility repair and regression tests integrated with the normal Vitest configurations. Local frozen-lock verification and independent review passed 75 unique tests, with network denied and no live credentials. The PR description now records the exact scope and limitations. Could a maintainer approve the pending workflow run https://github.com/tigrisdata/storage/actions/runs/38593140094 and review the bounded ifAbsent / --if-absent API? GitHub currently reports action_required with no jobs. I have kept this draft and have not attempted to bypass the approval gate. Please use only your approved CI/test environment; this request does not ask you to expose credentials to this fork. No hosted CI pass or live Tigris qualification is claimed. |
|
@primetimeindy We have implemented this in #423. Shall I close this PR? |
Summary
Adds an opt-in create-only upload path:
put(key, body, { ifAbsent: true }).tigris objects put BUCKET KEY FILE --if-absent --access private.If-None-Match: *on the actual single-part PUT. Conflicts remain errors, with no unconditional fallback.allowOverwritebehavior,cpand native authentication code.constantsandfstatSyncAPIs so browser bundling remains compatible.allowOverwrite: falsecurrently performs a HEAD precheck before an ordinary upload. This additive option closes the check-then-write race without silently changing that existing API.Current verification, head 72d7077
Hosted CI
Current-head run: https://github.com/tigrisdata/storage/actions/runs/38593140094
Observed
action_required, zero jobs, awaiting maintainer approval. No hosted CI success is claimed. This PR remains draft.Remaining limits
An earlier standalone harness remains included for serialization diagnostics. The repository-native tests now provide the regular test-runner coverage; the initial dependency-version mismatch has been resolved in the verification above.
This is a draft for maintainer feedback. Is the bounded opt-in interface appropriate, or would maintainers prefer broader multipart support in a separate change?
Assisted by GPT-6.1-sol and GPT-6-astra through Hermes Agent.