Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add uploadEmptyFiles Configuration to S3.uploadFile #1293

Open
wants to merge 13 commits into
base: main
Choose a base branch
from

Conversation

rodrigo-molina
Copy link

@rodrigo-molina rodrigo-molina commented Jan 27, 2025

Introduce uploadEmptyFiles boolean configuration for the S3.uploadFile method, defaulting to false.

Key updates:

  1. Signature Consistency:

    • Both uploadFile and uploadFileMultipart now return Pipe[F, Byte, Option[ETag]].
    • Both methods support skipping empty files when uploadEmptyFiles is disabled.
  2. Breaking Changes:

    • The return type of uploadFile is updated from Pipe[F, Byte, ETag] to Pipe[F, Byte, Option[ETag]].
    • The awsRequestModifier argument position has been changed to align with the uploadFileMultipart signature, now appearing after the uploadEmptyFiles parameter.
    • Provided there is already a breaking signature change, parameters awsRequestModifier, requestModifier, and modifier are now uniformly named awsRequestModifier.

This commit introduces a new `uploadEmptyFiles` boolean configuration for the `S3.uploadFile` method, defaulting to `false`.

Key updates:
1. **Signature Consistency:**
   - Both `uploadFile` and `uploadFileMultipart` now return `Pipe[F, Byte, Option[ETag]]`.
   - Both methods support skipping empty files when `uploadEmptyFiles` is disabled.

2. **Breaking Changes:**
   - The return type of `uploadFile` is updated from `Pipe[F, Byte, ETag]` to `Pipe[F, Byte, Option[ETag]]`.
   - The `awsRequestModifier` argument position has been changed to align with the `uploadFileMultipart` signature, now appearing after the `uploadEmptyFiles` parameter.
@rodrigo-molina
Copy link
Author

Let me know if you'd prefer to avoid the breaking changes. If so, we can keep the existing uploadFile method unchanged and introduce a new method with a different name for the updated implementation.

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