By Asored
I’m trying to use Digital Ocean Spaces as file storage for my Flutter application. As API helper I’m using the package minio (https://pub.dev/packages/minio).
In general I can start upload and download operations. But I can’t find a way to get progress informations.
I tried to set a bucket event like this:
void bucketListener() {
// Listener
final poller = minio.listenBucketNotification(bucket, events: [
's3:PutObject:*',
]);
poller.stream.listen((event) {
print(event);
print('--- event: ${event['eventName']}');
// Get.find<EntriesController>(tag: "newEntry").videoUploadProgress[0];
});
}
But this listener not fires. Then here I found that Digital Ocean does not support Bucket Informations: https://developers.digitalocean.com/documentation/spaces/
Is there a way to get the upload progress when using the Digital Ocean storage? Thanks for your help!
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
Heya,
To implement upload progress tracking in your Flutter application when using DigitalOcean Spaces, you can consider the following client-side approaches:
Track Upload Progress on the Client Side: You can track the upload progress on the client side using Flutter itself. The minio package you mentioned may not provide a built-in way to track progress, but you can implement it manually using Flutter’s own mechanisms. You would typically need to divide the file into chunks and update the progress as each chunk is uploaded.
Custom Backend for Progress Tracking: Create a custom backend server that interacts with DigitalOcean Spaces and serves as an intermediary between your Flutter app and Spaces. The backend can track upload progress and provide progress updates to your Flutter app through an API. This way, you can have more control over progress tracking.
Hope that this helps!
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.