-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Support for chunked file uploads #16
Comments
I noticed this feature before but haven't had time to do it yet. It's very welcome if you could give it a try. The documentation of elFinder client has a section about chunked upload. |
Hi @benny-adiwijaya, |
Hi @trannamtrung1st , your work is amazing.. when upload still progressing and user reload elfinder client, user can see temporary directory for chunk files.. Is it possible to hide those temporary directory from elfinder client? |
Hi @benny-adiwijaya, I see that too. I'm working on a way to abort the command and clean temp files. Since those temp files would occupy a large portion of the server storage if we failed to clean them, we must have an efficient approach to make sure those files are deleted if not needed anymore. |
Hi there @benny-adiwijaya, |
Hi @trannamtrung1st thanks for the update, I already pull the latest repository but when I try to upload file more than 15MB in demo project I get error Invalid parameters for command "upload". Do you have any idea why? |
Hi @benny-adiwijaya, |
Hi @trannamtrung1st, The file is mp4.. yes, I cloned the latest commit.. the only change I make is QuotaInBytes in program.cs so I can upload more than 10MB |
Do you have any authorization or filter applied? Can you send me that video if possible so I can make sure that is not a problem with that file? |
It works totally fine for me. This is a clean source without any modification or preparation. bandicam.2021-07-26.21-52-04-222.mp4 |
Hi @trannamtrung1st, when using drag & drop it works but when using upload button its not.. I dont use any authorization or filter applied and I think its not file problem |
Hi @benny-adiwijaya, |
Hi @trannamtrung1st thank you, this project is superb.. I have a question about performance, do you think the upload speed already fast or it can be optimize? |
As I see, the elFinder.Net.Demo31 is faster than the advanced project since the implementation of the QuotaManagement plugin relies on some synchronization mechanisms (lock, SemaphoreSlim) which make things slower. |
Allright noted, btw I have a case.. In my project I have some volume with separate drive storage.. I want location temp folder is inside volume path, so the temporary files copied to volume storage instead of server storage.. So, is it possible to create more than one temp folder (one temp folder each volume), and customize TempFileCleanerOptions dynamically? |
Currently, I don't allow those temp folders to be inside the volume directory since it will be difficult to manage size, and users may modify those folders and cause trouble. For multiple temp folders, it is possible since it is the volume's property. You may want to structure it like below:
You can customize the request/response of the connector to support your custom logic based on the Volume-[n] directory. The TempFileCleanerOptions can be retrieved using IOptionsMonitor and modified directly. |
Okay, lets say I have 3 volumes that saved on the database(Alpha, Beta, Charlie) How to set TempFileCleanerOptions dynamically in Startup.cs? Can I set something like this: services.AddElFinderAspNetCore() I'm not sure if I can retrieve data from database in ConfigureServices or it should hardcode like this: services.AddElFinderAspNetCore() Do you have other solution? |
You should inject the See Microsoft docs for more detail about using IOptionsMonitor. |
The purpose of the ITempFileCleaner service is to clean the files after an amount of time since its last access time. So basically you should add all of your temp folders to the ScanFolders property. It can be achieved in many ways. |
Okay, I got it thank you.. btw I am using event _driver.OnAfterUpload in FilesController for logging but don't want to log every chunks uploaded, so I changed to _driver.OnAfterChunkMerged. It works but there some issue:
I am not using logging interceptor because I think it will make the performance slower. So, is there a better way to log all uploaded file without chunk file in FilesController? |
OnAfterUpload's event has the IsChunking argument which will help differentiate between chunked upload and normal upload. |
Hi,
Is it possible to use elFinder chunked file upload feature in this project for handling large file?
The text was updated successfully, but these errors were encountered: