So its been weeks that I’m trying to make it work but still its not working up to mark. Which leaves me with only one option i.e. going native swift/kotlin and use method channels.
Use case:
- I’ve an app that is 90% of the time being used at low connectivity areas (Rally racings)
- It has 2 major feature, upload videos & watch those videos.
- The uploading part is currently being recorded by native code, bcz we needed some native lenses access so swift/kotlin does that job.
- Once the video is recorded, it is supposed to be send to R2 bucket via presigned URL (Return by an API)
In our real testing we found out that 234 events was reported on Crashlytics for R2 rejecting the video for a lot of users maybe due to internet disruption, app being in background etc. However, I already have:
- Retry on failure (3 times)
- On app restart, the queue continues from where it left (SQFlite in use)
But the actual problem is this: Background Uploading Explained. I’m migrating their old iOS app to flutter, and presinged URLs wasn’t being used in that app. They are being used now, so i’m facing this trouble. The old iOS as was using awsS3TransferUtility which gave them an edge of multi-parts upload, resume, background handling etc.
What is the possible shot for me? Except going native. I’ve tried the following solution
- background_downloader | Flutter package | Can’t make it work with presigned as per issue
- cloudflare_r2 | Dart package | Again, works but doesn’t support presigned URLs
- aws_s3_upload_lite | Flutter package | Has no support for R2, internal code only supports S3 URLs and buckets.
Any help would be appretiated ,before going into long journey of implementing this via native swift/kotlin.
Thanks