feat: add allow_custom_keys support, requestBulkUploadUrls mutation, auto-path derivation#1058
Merged
pyramation merged 2 commits intomainfrom May 5, 2026
Merged
feat: add allow_custom_keys support, requestBulkUploadUrls mutation, auto-path derivation#1058pyramation merged 2 commits intomainfrom
pyramation merged 2 commits intomainfrom
Conversation
…auto-path derivation - Add optional 'key' input to requestUploadUrl for custom S3 keys - Custom keys require bucket.allow_custom_keys=true - Re-uploading to existing custom key auto-versions (previous_version_id) - Dedup by content_hash in both hash-based and custom-key modes - Auto-derive ltree path from custom key directory when has_path_shares=true - Add requestBulkUploadUrls mutation with per-storage-module limits - Add max_bulk_files and max_bulk_total_size to StorageModuleConfig - Add has_path_shares to StorageModuleConfig for path column awareness - Validate custom keys: no traversal, no leading slash, alphanumeric start
Contributor
🤖 Devin AI EngineerI'll be helping with this pull request! Here's what you should know: ✅ I will automatically:
Note: I can only respond to comments from users who have write access to this repository. ⚙️ Control Options:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Phase 3a + 3b of the storage roadmap: adds
allow_custom_keyssupport to the presigned URL plugin, therequestBulkUploadUrlsmutation, and auto-path derivation from custom keys.Custom key support (Phase 3a):
requestUploadUrlnow accepts an optionalkeyinput fieldallow_custom_keys=trueon the bucket, clients can provide a custom S3 key (e.g.,reports/2024/Q1.pdf)keyis omitted, falls back to content-hash-based dedup (today's behavior)..), no leading/, max 1024 chars, regex-validatedprevious_version_id)RequestUploadUrlPayloadnow includespreviousVersionIdfieldBulk upload mutation (Phase 3b):
requestBulkUploadUrlsmutation — batch presigned URL generationmaxBulkFilesandmaxBulkTotalSizefrom storage module config (nullable DB columns with plugin-level defaults: 100 files / 1GB)processSingleFile()logic between single and bulk mutationsAuto-path derivation:
allow_custom_keys=trueANDhas_path_shares=true,pathltree column auto-derived from S3 key directory (e.g.,reports/2024/Q1/revenue.pdf→reports.2024.Q1)Cache/type updates:
has_path_shares,max_bulk_files,max_bulk_total_sizeallow_custom_keysReview & Testing Checklist for Human
..), leading/, null bytes, and keys > 1024 charsmaxBulkFiles,maxBulkTotalSize) returns correct errorscd graphql/server-test && pnpm test -- upload.integrationallow_custom_keys=false(default) rejects custom keys withCUSTOM_KEY_NOT_ALLOWEDerrorNotes
allow_custom_keys,content_hash, bulk limit columns) which depends on PR docs: update graphile-llm README with standard header #1010 (version_history computed function)BulkUploadFileInput,RequestBulkUploadUrlsInput,BulkUploadFilePayload,RequestBulkUploadUrlsPayloadLink to Devin session: https://app.devin.ai/sessions/ffa3ed8652fc412f976accbdc229c88d
Requested by: @pyramation