jijo-paulose / gwtupload

Automatically exported from code.google.com/p/gwtupload
Other
0 stars 0 forks source link

MultiUploader is not functioning correctly #129

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Embed a MultiUploader widget into a webapp.
2. Set max upload to 2 for MultiUploader, via GWT
3. Upload 2 files.

What is the expected output? What do you see instead?
I expect to see the colors of the uploader labels change to GREEN when 
successful, however the colors remains RED. Though the colors are red, the 
MultiUploader reports that it is "Done". When the colors are red, I can upload 
3 files.

In addition, the uploads are very unreliable. Sometimes the uploader fails with 
a java.io.FileNotFoundException.

What version of the product are you using? On what operating system?
0.6.4

Original issue reported on code.google.com by Chrn...@gmail.com on 23 Nov 2011 at 6:36

GoogleCodeExporter commented 9 years ago
Please check if the demo project works for you, it does pretty well in my 
system.
Download it from 
http://repo1.maven.org/maven2/com/googlecode/gwtupload/gwtupload-samples/0.6.4/g
wtupload-samples-0.6.4.war and deploy it in any tomcat or jetty server and it 
should work.
You can test it online at http://gwtupload.alcala.org

GWTupload is being used in many production systems and it behaves and performs 
well. 

It seems your server side code has any problem, attach your code so as we could 
take a look.

Original comment by manuel.carrasco.m on 27 Nov 2011 at 12:58

GoogleCodeExporter commented 9 years ago
After some extensive testing, I figured out that the error was not in the 
server side but the client side.

Originally, I had the following OnChangeUploaderHandler attached to the 
MultiUploader:

    @Override
    public void onChange(IUploader uploader) {
        uploader.submit();
    }

This code was actually called twice when the user selected a file, causing the 
intermittent results I observed. The fix was simply to add an if statement as 
seen below:

    @Override
    public void onChange(IUploader uploader) {
      if(uploader.getStatus()==Status.QUEUED){
        uploader.submit();
      }
    }

Original comment by Chrn...@gmail.com on 13 Dec 2011 at 4:15

GoogleCodeExporter commented 9 years ago
Does this continue being an issue with last snapshot?
Is there any patch to apply to the code?

thanks
- Manolo

Original comment by manuel.carrasco.m on 1 Jun 2012 at 10:28

GoogleCodeExporter commented 9 years ago
This issue does not happen with last release, please update to 0.6.5

Thanks for reporting

Original comment by manuel.carrasco.m on 3 Dec 2012 at 9:04