[
http://jira.jboss.com/jira/browse/RF-3056?page=all ]
Andrei Markavtsov resolved RF-3056.
-----------------------------------
Resolution: Rejected
Assignee: Aleksej Yanul (was: Andrei Markavtsov)
Tim,
Init parameters for Ajax4Jsf filter should be defined for Seam Filter if you use RF
together with Seam.
Simple thing to fire your application properlly :
....
....
<!-- comment Ajax4Jsf definition -->
<!--
<filter>
<display-name>RichFaces Filter</display-name>
<filter-name>richfaces</filter-name>
<filter-class>org.ajax4jsf.Filter</filter-class>
<init-param>
<param-name>createTempFiles</param-name>
<param-value>false</param-value>
</init-param>
<init-param>
<param-name>maxRequestSize</param-name>
<param-value>102400</param-value>
</init-param>
</filter>
<filter-mapping>
<filter-name>richfaces</filter-name>
<servlet-name>Faces Servlet</servlet-name>
<dispatcher>REQUEST</dispatcher>
<dispatcher>FORWARD</dispatcher>
<dispatcher>INCLUDE</dispatcher>
</filter-mapping>
-->
<!-- Seam -->
<listener>
<listener-class>
org.jboss.seam.servlet.SeamListener
</listener-class>
</listener>
<!-- Define params for Seam filter -->
<filter>
<filter-name>Seam Filter</filter-name>
<filter-class>org.jboss.seam.servlet.SeamFilter</filter-class>
<init-param>
<param-name>createTempFiles</param-name>
<param-value>false</param-value>
</init-param>
<init-param>
<param-name>maxRequestSize</param-name>
<param-value>102400</param-value>
</init-param>
</filter>
...
The fileUpload component in 3.2.1-SNAPSHOT is ignoring init-params in
web.xml.
------------------------------------------------------------------------------
Key: RF-3056
URL:
http://jira.jboss.com/jira/browse/RF-3056
Project: RichFaces
Issue Type: Bug
Affects Versions: 3.2.1
Environment: JBoss 4.2.2
JRE 1.5.0_15
Windows XP SP2 fully patched
Reporter: Tim Goodchild
Assigned To: Aleksej Yanul
Attachments: sandbox.ear
The fileUpload component in 3.2.1-SNAPSHOT is ignoring init-params in web.xml.
In 3.2.0GA there was no data uploaded at all and a fix was made to workaround an issue in
JSF 1.2_04; I was then asked to try the snapshot build.
The conversation is at:-
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4141901#...
I will attach a simple ear file which clearly demostrates the issue.
The ear was created in eclipse using JBoss Developer Studio which is using Seam 2.0.1 and
I created an empty ear project using Seam Gen
Inside the web.xml you will see:-
<filter>
<display-name>RichFaces Filter</display-name>
<filter-name>richfaces</filter-name>
<filter-class>org.ajax4jsf.Filter</filter-class>
<init-param>
<param-name>createTempFiles</param-name>
<param-value>false</param-value>
</init-param>
<init-param>
<param-name>maxRequestSize</param-name>
<param-value>102400</param-value>
</init-param>
</filter>
Load the ear (context path is "sandbox") to JBoss 4.2.2 and the home page will
show the fileUpload component.
Upload a picture and you will see a few debug messages as below
[STDOUT] item: org.richfaces.model.UploadItem@21251c
[STDOUT] item.getData(): null
[STDOUT] item.getFileName(): wsddclasses.jpg
[STDOUT] item.getFile():
C:\DOCUME~1\Tim\LOCALS~1\Temp\686631d9-11942495bde--7f8d18646.upload
[STDOUT] File has been saved in a temp file
[STDOUT] Deleted temp file:false
According to the above params I should not have had a temp file and I should not have
been able to upload anything greater than 100KB. In addition it seems that the temp file
is locked and I was unable to delete it after reading its contents. These temp files are
not cleaned up.
It's worth noting that the exadel live demo war runs on the same server with no
problems. So I wonder is Seam configuration interfering in any way, rather than only a
JSF issue?
This is my first JIRA on an open source project so please forgive me if I have missed
anything.
Best Regards,
Tim
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira