Uploading fails
[Logo]
ICEfaces Forums
[Search] Search   [Recent Topics] Recent Topics   [Groups] Home Page | www.icefaces.org  [Register] Register  [Login] Login 
Uploading fails  XML
Forum Index -> General Help
Author Message
jesus@aplsoftware.com

Joined: 12/04/2008 00:00:00
Messages: 6
Offline


After changing my program into release 1.7, I am not able to upload files more than once.
Everything was working fine using release 1.6.5.
Searching Jira, I see something nearly similar in an old 1.6 release error:
Key ICE-1468 excerpt:
File uploads were mysteriously failing, with no exceptions or messages or actionListener invocation.
Any error, even the ones properly trapped and messaged, would result in actionListener not being invoked. 


More clues:
FileInfo has no Exception, PhysicalPath is Ok pointing to the right one, FileName is Ok, percent is 100%, contentType and size, BUT there is no file uploaded into the path...

any ideas?

georges.goebel@pch.etat.l


Joined: 23/06/2007 00:00:00
Messages: 141
Offline


hi,

can you post your code.

georges
[Email]
jesus@aplsoftware.com

Joined: 12/04/2008 00:00:00
Messages: 6
Offline


I have copied the ICEface example, that is fairly simple, and now it works perfectly.
Basically, I have suppressed RenderManager.

Progress method was like this:

Code:
	public void progress(EventObject event) {
 		InputFile file = (InputFile) event.getSource();
 
 		this.percent = file.getFileInfo().getPercent();
 		if (this.file == null) {
 		    setFile(inputFile.getFile()); 
 		}
 
 		if (renderManager != null) {
 // Next line did not work, either (Taken from an example)
 //			renderManager.getOnDemandRenderer(sessionId).requestRender();
 		    renderManager.requestRender(this);
 
 		}
 
 		try {
 			if (state != null) {
 				state.render();
 			}
 		} catch (RenderingException e) {
 		}
 		    
 		
 	}


and now it is like this:


Code:
   public void progress(EventObject event) {
         InputFile file = (InputFile) event.getSource();
         this.percent = file.getFileInfo()
             .getPercent();
     }


Next days, I'll try to understand why...
georges.goebel@pch.etat.l


Joined: 23/06/2007 00:00:00
Messages: 141
Offline


Hi,

Yes, they changed the fileupload component in icefaces 1.7.1. You need not implement the interface renderable in the component.

Do you use Seam ? If so, check out alos the latest seam-component-testcase example.

Georges
[Email]
mark.collette


Joined: 07/02/2005 00:00:00
Messages: 1162
Offline


The bean code does not need to invoke the RenderManager anymore, because the example uses the new progressRender="true" attribute setting on the <ice:inputFile> component.

But you can leave it the old way, and not take advantage of this, in which case you will have to implement Renderable, and use the RenderManager.
[Email]
 
Forum Index -> General Help
Go to:   
Powered by JForum 2.1.7ice © JForum Team