Open
Conversation
Define data structures for multipart upload requests and responses including validation rules
Implement CompleteMultipartUpload with proper metadata retrieval and index updates
Add handler for initiating multipart uploads with permission checks and presigned URL generation
Add handler for completing multipart uploads with part assembly and metadata response
Clean up placeholder implementations now that actual handlers are implemented
Add comprehensive unit tests for request validation and reserved path checking
Move UploadMultipart and UploadComplete implementations from separate files (blob_handler_multipart.go and blob_handler_complete.go) into the main blob_handler.go file. This consolidation improves code organization and maintainability by keeping all blob-related handlers in a single location. - Move UploadMultipart method to handle multipart upload initiation - Move UploadComplete method to handle multipart upload completion - Remove redundant separate handler files - Add required fmt import for error formatting
Contributor
|
holding off on this change - there's a bigger pr that's coming in on the client's |
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.
This pull request introduces multipart upload functionality to the blob handling system, including API endpoints, request/response types, and validation tests. The changes enhance the system's ability to handle large file uploads efficiently by splitting them into smaller parts. Key updates include implementing multipart upload and completion logic, adding request/response structures, and comprehensive validation testing.
Multipart Upload Functionality
Implementation of multipart upload logic: Added
UploadMultipartandUploadCompletemethods toBlobHandlerto initiate and complete multipart uploads, including validation of paths, permissions, and request parameters. (internal/server/handlers/blob/blob_handler.go, internal/server/handlers/blob/blob_handler.goR70-R179)Integration with S3 backend: Updated
CompleteMultipartUploadinS3Backendto retrieve object metadata and invoke hooks for post-upload processing. (internal/server/blob/blob_backend_s3.go, internal/server/blob/blob_backend_s3.goL225-R252)Request and Response Structures
MultipartUploadRequest,MultipartUploadResponse,CompleteUploadRequest, andCompleteUploadResponseto define request and response formats for multipart upload operations. (internal/server/handlers/blob/blob_handler_types.go, internal/server/handlers/blob/blob_handler_types.goR66-R96)Validation and Testing
internal/server/handlers/blob/blob_handler_validation_test.go, internal/server/handlers/blob/blob_handler_validation_test.goR1-R243)Affected Dependencies
List any dependencies that are required for this change.
How has this been tested?
Checklist